Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion API_VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
7684500f9744e3dbcd9b4b87db96f2e919c105aa
7684500f9744e3dbcd9b4b87db96f2e919c105aa
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@
* Add support for `allocated_funds` on `Charge`, `PaymentIntentConfirmParams`, `PaymentIntentCreateParams`, and `PaymentIntentModifyParams`
* Add support for thin events `V2ReportingReportRunCreatedEvent`, `V2ReportingReportRunFailedEvent`, `V2ReportingReportRunSucceededEvent`, and `V2ReportingReportRunUpdatedEvent` with related object `v2.reporting.ReportRun`

## 13.2.0 - 2025-11-05
* [#1662](https://github.com/stripe/stripe-python/pull/1662) Update generated code
* Add support for `capture_method` on `PaymentIntent.PaymentMethodOption.CardPresent`, `PaymentIntentConfirmParamsPaymentMethodOptionCardPresent`, `PaymentIntentCreateParamsPaymentMethodOptionCardPresent`, and `PaymentIntentModifyParamsPaymentMethodOptionCardPresent`

## 13.2.0b1 - 2025-10-29

This release changes the pinned API version to `2025-10-29.preview`.
Expand Down
2 changes: 1 addition & 1 deletion OPENAPI_VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v2110
v2110
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -275,6 +275,8 @@ Stripe has features in the [private preview phase](https://docs.stripe.com/relea

### Custom requests

> This feature is only available from version 11 of this SDK.

If you would like to send a request to an undocumented API (for example you are in a private beta), or if you prefer to bypass the method definitions in the library and specify your request details directly, you can use the `raw_request` method on `StripeClient`.

```python
Expand Down
2 changes: 1 addition & 1 deletion deps/test-requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ anyio[trio] == 4.11.0; python_version >= "3.13"
pytest-mock >= 2.0.0
mock >= 4.0; python_version < "3.8"
pytest-xdist >= 1.31.0
pytest >= 6.0.0
pytest >= 6.0.0,<9.0.0
2 changes: 1 addition & 1 deletion stripe/_account.py
Original file line number Diff line number Diff line change
Expand Up @@ -1414,7 +1414,7 @@ class Invoices(StripeObject):
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.
Whether to save the payment method after a payment is completed for a one-time invoice or a subscription invoice when the customer already has a default payment method on the hosted invoice page.
"""

class Payments(StripeObject):
Expand Down
2 changes: 1 addition & 1 deletion stripe/_invoice.py
Original file line number Diff line number Diff line change
Expand Up @@ -1406,7 +1406,7 @@ class TaxRateDetails(StripeObject):
* `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.
* `upcoming`: Reserved for upcoming invoices created through the Create Preview Invoice API or when an `invoice.upcoming` event is generated for an upcoming invoice on a subscription.
"""
collection_method: Literal["charge_automatically", "send_invoice"]
"""
Expand Down
4 changes: 4 additions & 0 deletions stripe/_payment_intent.py
Original file line number Diff line number Diff line change
Expand Up @@ -2256,6 +2256,10 @@ class Routing(StripeObject):
Requested routing priority
"""

capture_method: Optional[Literal["manual", "manual_preferred"]]
"""
Controls when the funds will be captured from the customer's account.
"""
request_extended_authorization: Optional[bool]
"""
Request ability to capture this payment beyond the standard [authorization validity window](https://stripe.com/docs/terminal/features/extended-authorizations#authorization-validity)
Expand Down
2 changes: 1 addition & 1 deletion stripe/params/_account_create_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -2137,7 +2137,7 @@ class AccountCreateParamsSettingsInvoices(TypedDict):
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.
Whether to save the payment method after a payment is completed for a one-time invoice or a subscription invoice when the customer already has a default payment method on the hosted invoice page.
"""


Expand Down
2 changes: 1 addition & 1 deletion stripe/params/_account_update_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -2053,7 +2053,7 @@ class AccountUpdateParamsSettingsInvoices(TypedDict):
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.
Whether to save the payment method after a payment is completed for a one-time invoice or a subscription invoice when the customer already has a default payment method on the hosted invoice page.
"""


Expand Down
2 changes: 1 addition & 1 deletion stripe/params/_customer_session_create_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
class CustomerSessionCreateParams(RequestOptions):
components: "CustomerSessionCreateParamsComponents"
"""
Configuration for each component. Exactly 1 component must be enabled.
Configuration for each component. At least 1 component must be enabled.
"""
customer: NotRequired[str]
"""
Expand Down
8 changes: 8 additions & 0 deletions stripe/params/_payment_intent_confirm_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -3026,6 +3026,14 @@ class PaymentIntentConfirmParamsPaymentMethodOptionsCardThreeDSecureNetworkOptio


class PaymentIntentConfirmParamsPaymentMethodOptionsCardPresent(TypedDict):
capture_method: NotRequired[Literal["manual", "manual_preferred"]]
"""
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.
"""
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)
Expand Down
8 changes: 8 additions & 0 deletions stripe/params/_payment_intent_create_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -3153,6 +3153,14 @@ class PaymentIntentCreateParamsPaymentMethodOptionsCardThreeDSecureNetworkOption


class PaymentIntentCreateParamsPaymentMethodOptionsCardPresent(TypedDict):
capture_method: NotRequired[Literal["manual", "manual_preferred"]]
"""
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.
"""
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)
Expand Down
8 changes: 8 additions & 0 deletions stripe/params/_payment_intent_modify_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -3011,6 +3011,14 @@ class PaymentIntentModifyParamsPaymentMethodOptionsCardThreeDSecureNetworkOption


class PaymentIntentModifyParamsPaymentMethodOptionsCardPresent(TypedDict):
capture_method: NotRequired[Literal["manual", "manual_preferred"]]
"""
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.
"""
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)
Expand Down
8 changes: 8 additions & 0 deletions stripe/params/_payment_intent_update_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -3010,6 +3010,14 @@ class PaymentIntentUpdateParamsPaymentMethodOptionsCardThreeDSecureNetworkOption


class PaymentIntentUpdateParamsPaymentMethodOptionsCardPresent(TypedDict):
capture_method: NotRequired[Literal["manual", "manual_preferred"]]
"""
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.
"""
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)
Expand Down
18 changes: 9 additions & 9 deletions stripe/params/terminal/_configuration_create_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@
class ConfigurationCreateParams(RequestOptions):
bbpos_wisepad3: NotRequired["ConfigurationCreateParamsBbposWisepad3"]
"""
An object containing device type specific settings for BBPOS WisePad 3 readers
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
An object containing device type specific settings for BBPOS WisePOS E readers.
"""
expand: NotRequired[List[str]]
"""
Expand All @@ -34,19 +34,19 @@ class ConfigurationCreateParams(RequestOptions):
"""
reboot_window: NotRequired["ConfigurationCreateParamsRebootWindow"]
"""
Reboot time settings for readers that support customized reboot time configuration.
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
An object containing device type specific settings for Stripe S700 readers.
"""
tipping: NotRequired["Literal['']|ConfigurationCreateParamsTipping"]
"""
Tipping configurations for readers supporting on-reader tips
Tipping configurations for readers. supporting on-reader tips
"""
verifone_p400: NotRequired["ConfigurationCreateParamsVerifoneP400"]
"""
An object containing device type specific settings for Verifone P400 readers
An object containing device type specific settings for Verifone P400 readers.
"""
wifi: NotRequired["Literal['']|ConfigurationCreateParamsWifi"]
"""
Expand All @@ -57,7 +57,7 @@ class ConfigurationCreateParams(RequestOptions):
class ConfigurationCreateParamsBbposWisepad3(TypedDict):
splashscreen: NotRequired["Literal['']|str"]
"""
A File ID representing an image you would like displayed on the reader.
A File ID representing an image you want to display on the reader.
"""


Expand Down Expand Up @@ -96,7 +96,7 @@ class ConfigurationCreateParamsRebootWindow(TypedDict):
class ConfigurationCreateParamsStripeS700(TypedDict):
splashscreen: NotRequired["Literal['']|str"]
"""
A File ID representing an image you would like displayed on the reader.
A File ID representing an image you want to display on the reader.
"""


Expand Down Expand Up @@ -524,7 +524,7 @@ class ConfigurationCreateParamsTippingUsd(TypedDict):
class ConfigurationCreateParamsVerifoneP400(TypedDict):
splashscreen: NotRequired["Literal['']|str"]
"""
A File ID representing an image you would like displayed on the reader.
A File ID representing an image you want to display on the reader.
"""


Expand Down
18 changes: 9 additions & 9 deletions stripe/params/terminal/_configuration_modify_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,13 @@ class ConfigurationModifyParams(RequestOptions):
"Literal['']|ConfigurationModifyParamsBbposWisepad3"
]
"""
An object containing device type specific settings for BBPOS WisePad 3 readers
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
An object containing device type specific settings for BBPOS WisePOS E readers.
"""
expand: NotRequired[List[str]]
"""
Expand All @@ -40,21 +40,21 @@ class ConfigurationModifyParams(RequestOptions):
"Literal['']|ConfigurationModifyParamsRebootWindow"
]
"""
Reboot time settings for readers that support customized reboot time configuration.
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
An object containing device type specific settings for Stripe S700 readers.
"""
tipping: NotRequired["Literal['']|ConfigurationModifyParamsTipping"]
"""
Tipping configurations for readers supporting on-reader tips
Tipping configurations for readers. supporting on-reader tips
"""
verifone_p400: NotRequired[
"Literal['']|ConfigurationModifyParamsVerifoneP400"
]
"""
An object containing device type specific settings for Verifone P400 readers
An object containing device type specific settings for Verifone P400 readers.
"""
wifi: NotRequired["Literal['']|ConfigurationModifyParamsWifi"]
"""
Expand All @@ -65,7 +65,7 @@ class ConfigurationModifyParams(RequestOptions):
class ConfigurationModifyParamsBbposWisepad3(TypedDict):
splashscreen: NotRequired["Literal['']|str"]
"""
A File ID representing an image you would like displayed on the reader.
A File ID representing an image you want to display on the reader.
"""


Expand Down Expand Up @@ -104,7 +104,7 @@ class ConfigurationModifyParamsRebootWindow(TypedDict):
class ConfigurationModifyParamsStripeS700(TypedDict):
splashscreen: NotRequired["Literal['']|str"]
"""
A File ID representing an image you would like displayed on the reader.
A File ID representing an image you want to display on the reader.
"""


Expand Down Expand Up @@ -532,7 +532,7 @@ class ConfigurationModifyParamsTippingUsd(TypedDict):
class ConfigurationModifyParamsVerifoneP400(TypedDict):
splashscreen: NotRequired["Literal['']|str"]
"""
A File ID representing an image you would like displayed on the reader.
A File ID representing an image you want to display on the reader.
"""


Expand Down
18 changes: 9 additions & 9 deletions stripe/params/terminal/_configuration_update_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,13 @@ class ConfigurationUpdateParams(TypedDict):
"Literal['']|ConfigurationUpdateParamsBbposWisepad3"
]
"""
An object containing device type specific settings for BBPOS WisePad 3 readers
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
An object containing device type specific settings for BBPOS WisePOS E readers.
"""
expand: NotRequired[List[str]]
"""
Expand All @@ -39,21 +39,21 @@ class ConfigurationUpdateParams(TypedDict):
"Literal['']|ConfigurationUpdateParamsRebootWindow"
]
"""
Reboot time settings for readers that support customized reboot time configuration.
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
An object containing device type specific settings for Stripe S700 readers.
"""
tipping: NotRequired["Literal['']|ConfigurationUpdateParamsTipping"]
"""
Tipping configurations for readers supporting on-reader tips
Tipping configurations for readers. supporting on-reader tips
"""
verifone_p400: NotRequired[
"Literal['']|ConfigurationUpdateParamsVerifoneP400"
]
"""
An object containing device type specific settings for Verifone P400 readers
An object containing device type specific settings for Verifone P400 readers.
"""
wifi: NotRequired["Literal['']|ConfigurationUpdateParamsWifi"]
"""
Expand All @@ -64,7 +64,7 @@ class ConfigurationUpdateParams(TypedDict):
class ConfigurationUpdateParamsBbposWisepad3(TypedDict):
splashscreen: NotRequired["Literal['']|str"]
"""
A File ID representing an image you would like displayed on the reader.
A File ID representing an image you want to display on the reader.
"""


Expand Down Expand Up @@ -103,7 +103,7 @@ class ConfigurationUpdateParamsRebootWindow(TypedDict):
class ConfigurationUpdateParamsStripeS700(TypedDict):
splashscreen: NotRequired["Literal['']|str"]
"""
A File ID representing an image you would like displayed on the reader.
A File ID representing an image you want to display on the reader.
"""


Expand Down Expand Up @@ -531,7 +531,7 @@ class ConfigurationUpdateParamsTippingUsd(TypedDict):
class ConfigurationUpdateParamsVerifoneP400(TypedDict):
splashscreen: NotRequired["Literal['']|str"]
"""
A File ID representing an image you would like displayed on the reader.
A File ID representing an image you want to display on the reader.
"""


Expand Down
3 changes: 2 additions & 1 deletion stripe/v2/billing/_meter_event.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,8 @@ class MeterEvent(StripeObject):
"""
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.
`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: str
"""
Expand Down