diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index f4d6dd6b8..22ff15f6c 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v1106 \ No newline at end of file +v1107 \ No newline at end of file diff --git a/stripe/_customer_session.py b/stripe/_customer_session.py index 931222605..f845c56f9 100644 --- a/stripe/_customer_session.py +++ b/stripe/_customer_session.py @@ -46,6 +46,14 @@ class Features(StripeObject): 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: Optional[ + 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. + """ payment_method_update: Literal["disabled", "enabled"] """ Controls whether the Payment Element displays the option to update a saved payment method. This parameter defaults to `disabled`. @@ -150,6 +158,14 @@ class CreateParamsComponentsPaymentElementFeatures(TypedDict): 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. + """ payment_method_update: NotRequired[Literal["disabled", "enabled"]] """ Controls whether the Payment Element displays the option to update a saved payment method. This parameter defaults to `disabled`. diff --git a/stripe/_customer_session_service.py b/stripe/_customer_session_service.py index 18a242d71..feffc7e73 100644 --- a/stripe/_customer_session_service.py +++ b/stripe/_customer_session_service.py @@ -73,6 +73,14 @@ class CreateParamsComponentsPaymentElementFeatures(TypedDict): 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. + """ payment_method_update: NotRequired[Literal["disabled", "enabled"]] """ Controls whether the Payment Element displays the option to update a saved payment method. This parameter defaults to `disabled`.