square_api_client/models/
external_payment_details.rs

1//! Model struct for ExternalPaymentDetails type.
2
3use serde::{Deserialize, Serialize};
4
5use super::{enums::ExternalPaymentType, Money};
6
7/// Stores details about an external payment.
8///
9/// Contains only non-confidential information. For more information, see [Take External
10/// Payments](https://developer.squareup.com/docs/payments-api/take-payments/external-payments).
11#[derive(Clone, Debug, Default, Deserialize, Eq, PartialEq, Serialize)]
12pub struct ExternalPaymentDetails {
13    /// The type of external payment the seller received.
14    pub r#type: Option<ExternalPaymentType>,
15    /// A description of the external payment source. For example, "Food Delivery Service".
16    pub source: Option<String>,
17    /// An ID to associate the payment to its originating source.
18    pub source_id: Option<String>,
19    /// The fees paid to the source. The `amount_money` minus this field is the net amount seller
20    /// receives.
21    pub source_fee_money: Option<Money>,
22}