pub struct CreateCheckoutSessionOptionalItems {
pub adjustable_quantity: Option<CreateCheckoutSessionOptionalItemsAdjustableQuantity>,
pub price: String,
pub quantity: u64,
}Expand description
A list of optional items the customer can add to their order at checkout. Use this parameter to pass one-time or recurring Prices.
There is a maximum of 10 optional items allowed on a Checkout Session, and the existing limits on the number of line items allowed on a Checkout Session apply to the combined number of line items and optional items.
For payment mode, there is a maximum of 100 combined line items and optional items, however it is recommended to consolidate items if there are more than a few dozen.
For subscription mode, there is a maximum of 20 line items and optional items with recurring Prices and 20 line items and optional items with one-time Prices.
You can’t set this parameter if ui_mode is custom.
Fields§
§adjustable_quantity: Option<CreateCheckoutSessionOptionalItemsAdjustableQuantity>When set, provides configuration for the customer to adjust the quantity of the line item created when a customer chooses to add this optional item to their order.
price: String§quantity: u64The initial quantity of the line item created when a customer chooses to add this optional item to their order.
Implementations§
Trait Implementations§
Source§impl Clone for CreateCheckoutSessionOptionalItems
impl Clone for CreateCheckoutSessionOptionalItems
Source§fn clone(&self) -> CreateCheckoutSessionOptionalItems
fn clone(&self) -> CreateCheckoutSessionOptionalItems
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more