pub struct UpdateSetupIntent { /* private fields */ }
Expand description
Updates a SetupIntent object.
Implementations§
Source§impl UpdateSetupIntent
impl UpdateSetupIntent
Sourcepub fn new(intent: impl Into<SetupIntentId>) -> Self
pub fn new(intent: impl Into<SetupIntentId>) -> Self
Construct a new UpdateSetupIntent
.
Sourcepub fn attach_to_self(self, attach_to_self: impl Into<bool>) -> Self
pub fn attach_to_self(self, attach_to_self: impl Into<bool>) -> Self
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.
Sourcepub fn customer(self, customer: impl Into<String>) -> Self
pub fn customer(self, customer: impl Into<String>) -> Self
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.
Sourcepub fn description(self, description: impl Into<String>) -> Self
pub fn description(self, description: impl Into<String>) -> Self
An arbitrary string attached to the object. Often useful for displaying to users.
Sourcepub fn expand(self, expand: impl Into<Vec<String>>) -> Self
pub fn expand(self, expand: impl Into<Vec<String>>) -> Self
Specifies which fields in the response should be expanded.
Sourcepub fn flow_directions(
self,
flow_directions: impl Into<Vec<SetupIntentFlowDirections>>,
) -> Self
pub fn flow_directions( self, flow_directions: impl Into<Vec<SetupIntentFlowDirections>>, ) -> Self
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.
Sourcepub fn metadata(self, metadata: impl Into<HashMap<String, String>>) -> Self
pub fn metadata(self, metadata: impl Into<HashMap<String, String>>) -> Self
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.
Individual keys can be unset by posting an empty value to them.
All keys can be unset by posting an empty value to metadata
.
Sourcepub fn payment_method(self, payment_method: impl Into<String>) -> Self
pub fn payment_method(self, payment_method: impl Into<String>) -> Self
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.
Sourcepub fn payment_method_configuration(
self,
payment_method_configuration: impl Into<String>,
) -> Self
pub fn payment_method_configuration( self, payment_method_configuration: impl Into<String>, ) -> Self
The ID of the payment method configuration to use with this SetupIntent.
Sourcepub fn payment_method_data(
self,
payment_method_data: impl Into<UpdateSetupIntentPaymentMethodData>,
) -> Self
pub fn payment_method_data( self, payment_method_data: impl Into<UpdateSetupIntentPaymentMethodData>, ) -> Self
When included, this hash creates a PaymentMethod that is set as the payment_method
.
value in the SetupIntent.
Sourcepub fn payment_method_options(
self,
payment_method_options: impl Into<UpdateSetupIntentPaymentMethodOptions>,
) -> Self
pub fn payment_method_options( self, payment_method_options: impl Into<UpdateSetupIntentPaymentMethodOptions>, ) -> Self
Payment method-specific configuration for this SetupIntent.
Sourcepub fn payment_method_types(
self,
payment_method_types: impl Into<Vec<String>>,
) -> Self
pub fn payment_method_types( self, payment_method_types: impl Into<Vec<String>>, ) -> Self
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.
Source§impl UpdateSetupIntent
impl UpdateSetupIntent
Sourcepub async fn send<C: StripeClient>(
&self,
client: &C,
) -> Result<<Self as StripeRequest>::Output, C::Err>
pub async fn send<C: StripeClient>( &self, client: &C, ) -> Result<<Self as StripeRequest>::Output, C::Err>
Send the request and return the deserialized response.
Sourcepub fn send_blocking<C: StripeBlockingClient>(
&self,
client: &C,
) -> Result<<Self as StripeRequest>::Output, C::Err>
pub fn send_blocking<C: StripeBlockingClient>( &self, client: &C, ) -> Result<<Self as StripeRequest>::Output, C::Err>
Send the request and return the deserialized response, blocking until completion.
Trait Implementations§
Source§impl Clone for UpdateSetupIntent
impl Clone for UpdateSetupIntent
Source§fn clone(&self) -> UpdateSetupIntent
fn clone(&self) -> UpdateSetupIntent
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more