pub struct PaymentLink {Show 33 fields
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 id: PaymentLinkId,
pub inactive_message: Option<String>,
pub invoice_creation: Option<PaymentLinksResourceInvoiceCreation>,
pub line_items: Option<List<CheckoutSessionItem>>,
pub livemode: bool,
pub metadata: HashMap<String, String>,
pub on_behalf_of: Option<Expandable<Account>>,
pub optional_items: Option<Vec<PaymentLinksResourceOptionalItem>>,
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
A payment link is a shareable URL that will take your customers to a hosted payment page. A payment link can be shared and used multiple times.
When a customer opens a payment link it will open a new checkout session to render the payment page. You can use checkout session events to track payments through payment links.
Related guide: Payment Links API
For more details see <https://stripe.com/docs/api/payment_links/payment_links/object>.
Fields§
§active: boolWhether 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: boolWhether 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: PaymentLinkBillingAddressCollectionConfiguration for collecting the customer’s billing address. Defaults to auto.
consent_collection: Option<PaymentLinksResourceConsentCollection>When set, provides configuration to gather active consent from customers.
currency: CurrencyThree-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: PaymentLinkCustomerCreationConfiguration for Customer creation during checkout.
id: PaymentLinkIdUnique identifier for the object.
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: boolHas the value true if the object exists in live mode or the value false if the object exists in test mode.
metadata: HashMap<String, String>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.
optional_items: Option<Vec<PaymentLinksResourceOptionalItem>>The optional items presented to the customer at checkout.
payment_intent_data: Option<PaymentLinksResourcePaymentIntentData>Indicates the parameters to be passed to PaymentIntent creation during checkout.
payment_method_collection: PaymentLinkPaymentMethodCollectionConfiguration for collecting a payment method during checkout. Defaults to always.
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: PaymentLinkSubmitTypeIndicates 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: StringThe public URL that can be shared with customers.
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