Struct stripe::PaymentLink
source · pub struct PaymentLink {Show 32 fields
pub id: PaymentLinkId,
pub active: bool,
pub after_completion: PaymentLinksResourceAfterCompletion,
pub allow_promotion_codes: bool,
pub application: Option<Expandable<Application>>,
pub application_fee_amount: Option<i64>,
pub application_fee_percent: Option<f64>,
pub automatic_tax: PaymentLinksResourceAutomaticTax,
pub billing_address_collection: PaymentLinkBillingAddressCollection,
pub consent_collection: Option<PaymentLinksResourceConsentCollection>,
pub currency: Currency,
pub custom_fields: Vec<PaymentLinksResourceCustomFields>,
pub custom_text: PaymentLinksResourceCustomText,
pub customer_creation: PaymentLinkCustomerCreation,
pub inactive_message: Option<String>,
pub invoice_creation: Option<PaymentLinksResourceInvoiceCreation>,
pub line_items: Option<List<CheckoutSessionItem>>,
pub livemode: bool,
pub metadata: Metadata,
pub on_behalf_of: Option<Expandable<Account>>,
pub payment_intent_data: Option<PaymentLinksResourcePaymentIntentData>,
pub payment_method_collection: PaymentLinkPaymentMethodCollection,
pub payment_method_types: Option<Vec<PaymentLinkPaymentMethodTypes>>,
pub phone_number_collection: PaymentLinksResourcePhoneNumberCollection,
pub restrictions: Option<PaymentLinksResourceRestrictions>,
pub shipping_address_collection: Option<PaymentLinksResourceShippingAddressCollection>,
pub shipping_options: Vec<PaymentLinksResourceShippingOption>,
pub submit_type: PaymentLinkSubmitType,
pub subscription_data: Option<PaymentLinksResourceSubscriptionData>,
pub tax_id_collection: PaymentLinksResourceTaxIdCollection,
pub transfer_data: Option<PaymentLinksResourceTransferData>,
pub url: String,
}
Expand description
The resource representing a Stripe “PaymentLink”.
For more details see https://stripe.com/docs/api/payment_links/payment_links/object
Fields§
§id: PaymentLinkId
Unique identifier for the object.
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.
after_completion: PaymentLinksResourceAfterCompletion
§allow_promotion_codes: bool
Whether user redeemable promotion codes are enabled.
application: Option<Expandable<Application>>
The ID of the Connect application that created the Payment Link.
application_fee_amount: Option<i64>
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.
application_fee_percent: Option<f64>
This represents the percentage of the subscription invoice total that will be transferred to the application owner’s Stripe account.
automatic_tax: PaymentLinksResourceAutomaticTax
§billing_address_collection: PaymentLinkBillingAddressCollection
Configuration for collecting the customer’s billing address.
consent_collection: Option<PaymentLinksResourceConsentCollection>
When set, provides configuration to gather active consent from customers.
currency: Currency
Three-letter ISO currency code, in lowercase.
Must be a supported currency.
custom_fields: Vec<PaymentLinksResourceCustomFields>
Collect additional information from your customer using custom fields.
Up to 3 fields are supported.
custom_text: PaymentLinksResourceCustomText
§customer_creation: PaymentLinkCustomerCreation
Configuration for Customer creation during checkout.
inactive_message: Option<String>
The custom message to be displayed to a customer when a payment link is no longer active.
invoice_creation: Option<PaymentLinksResourceInvoiceCreation>
Configuration for creating invoice for payment mode payment links.
line_items: Option<List<CheckoutSessionItem>>
The line items representing what is being sold.
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: Metadata
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.
on_behalf_of: Option<Expandable<Account>>
The account on behalf of which to charge.
See the Connect documentation for details.
payment_intent_data: Option<PaymentLinksResourcePaymentIntentData>
Indicates the parameters to be passed to PaymentIntent creation during checkout.
payment_method_collection: PaymentLinkPaymentMethodCollection
Configuration for collecting a payment method during checkout.
payment_method_types: Option<Vec<PaymentLinkPaymentMethodTypes>>
The list of payment method types that customers can use.
When null
, Stripe will dynamically show relevant payment methods you’ve enabled in your payment method settings.
phone_number_collection: PaymentLinksResourcePhoneNumberCollection
§restrictions: Option<PaymentLinksResourceRestrictions>
Settings that restrict the usage of a payment link.
shipping_address_collection: Option<PaymentLinksResourceShippingAddressCollection>
Configuration for collecting the customer’s shipping address.
shipping_options: Vec<PaymentLinksResourceShippingOption>
The shipping rate options applied to the session.
submit_type: PaymentLinkSubmitType
Indicates the type of transaction being performed which customizes relevant text on the page, such as the submit button.
subscription_data: Option<PaymentLinksResourceSubscriptionData>
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: PaymentLinksResourceTaxIdCollection
§transfer_data: Option<PaymentLinksResourceTransferData>
The account (if any) the payments will be attributed to for tax reporting, and where funds from each payment will be transferred to.
url: String
The public URL that can be shared with customers.
Implementations§
source§impl PaymentLink
impl PaymentLink
sourcepub fn list(
client: &Client,
params: &ListPaymentLinks<'_>
) -> Response<List<PaymentLink>>
pub fn list( client: &Client, params: &ListPaymentLinks<'_> ) -> Response<List<PaymentLink>>
Returns a list of your payment links.
sourcepub fn create(
client: &Client,
params: CreatePaymentLink<'_>
) -> Response<PaymentLink>
pub fn create( client: &Client, params: CreatePaymentLink<'_> ) -> Response<PaymentLink>
Creates a payment link.
sourcepub fn retrieve(
client: &Client,
id: &PaymentLinkId,
expand: &[&str]
) -> Response<PaymentLink>
pub fn retrieve( client: &Client, id: &PaymentLinkId, expand: &[&str] ) -> Response<PaymentLink>
Retrieve a payment link.
sourcepub fn update(
client: &Client,
id: &PaymentLinkId,
params: UpdatePaymentLink<'_>
) -> Response<PaymentLink>
pub fn update( client: &Client, id: &PaymentLinkId, params: UpdatePaymentLink<'_> ) -> Response<PaymentLink>
Updates a payment link.
Trait Implementations§
source§impl Clone for PaymentLink
impl Clone for PaymentLink
source§fn clone(&self) -> PaymentLink
fn clone(&self) -> PaymentLink
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more