pub struct CreatePromotionCodeRestrictions {
pub currency_options: Option<HashMap<Currency, CurrencyOption>>,
pub first_time_transaction: Option<bool>,
pub minimum_amount: Option<i64>,
pub minimum_amount_currency: Option<Currency>,
}Expand description
Settings that restrict the redemption of the promotion code.
Fields§
§currency_options: Option<HashMap<Currency, CurrencyOption>>Promotion codes defined in each available currency option. Each key must be a three-letter ISO currency code and a supported currency.
first_time_transaction: Option<bool>A Boolean indicating if the Promotion Code should only be redeemed for Customers without any successful payments or invoices.
minimum_amount: Option<i64>Minimum amount required to redeem this Promotion Code into a Coupon (e.g., a purchase must be $100 or more to work).
minimum_amount_currency: Option<Currency>Three-letter ISO code for minimum_amount
Implementations§
Trait Implementations§
Source§impl Clone for CreatePromotionCodeRestrictions
impl Clone for CreatePromotionCodeRestrictions
Source§fn clone(&self) -> CreatePromotionCodeRestrictions
fn clone(&self) -> CreatePromotionCodeRestrictions
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for CreatePromotionCodeRestrictions
impl RefUnwindSafe for CreatePromotionCodeRestrictions
impl Send for CreatePromotionCodeRestrictions
impl Sync for CreatePromotionCodeRestrictions
impl Unpin for CreatePromotionCodeRestrictions
impl UnsafeUnpin for CreatePromotionCodeRestrictions
impl UnwindSafe for CreatePromotionCodeRestrictions
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more