1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47
//! Model struct for GiftCardActivityLoad type
use serde::{Deserialize, Serialize};
use super::Money;
/// Represents details about a `LOAD` [gift card activity type](GiftCardActivityType).
#[derive(Clone, Debug, Default, Deserialize, Eq, PartialEq, Serialize)]
pub struct GiftCardActivityLoad {
/// The amount added to the gift card. This value is a positive integer.
///
/// Applications that use a custom order processing system must specify this amount in the
/// [CreateGiftCardActivity](https://developer.squareup.com/reference/square/giftcardactivities-api/create-gift-card-activity)
/// request.
pub amount_money: Option<Money>,
/// The payment instrument IDs used to process the order for the additional funds, such as a
/// credit card ID or bank account ID.
///
/// Applications that use a custom order processing system must specify payment instrument IDs
/// in the
/// [CreateGiftCardActivity](https://developer.squareup.com/reference/square/giftcardactivities-api/create-gift-card-activity)
/// request. Square uses this information to perform compliance checks.
///
/// For applications that use the Square Orders API to process payments, Square has the
/// necessary instrument IDs to perform compliance checks.
pub buyer_payment_instrument_ids: Option<Vec<String>>,
/// The UID of the `GIFT_CARD` line item in the order that represents the additional funds for
/// the gift card.
///
/// Applications that use the Square Orders API to process orders must specify the line item UID
/// in the
/// [CreateGiftCardActivity](https://developer.squareup.com/reference/square/giftcardactivities-api/create-gift-card-activity)
/// request.
pub line_item_uid: Option<String>,
/// The ID of the [Order] that contains the GIFT_CARD line item.
///
/// Applications that use the Square Orders API to process orders must specify the order ID
/// [CreateGiftCardActivity](https://developer.squareup.com/reference/square/giftcardactivities-api/create-gift-card-activity)
/// request.
pub order_id: Option<String>,
/// A client-specified ID that associates the gift card activity with an entity in another
/// system.
///
/// Applications that use a custom order processing system can use this field to track
/// information related to an order or payment.
pub reference_id: Option<String>,
}