paypal_rust/resources/
payment_method.rs

1use crate::resources::enums::payee_preferred::PayeePreferred;
2use crate::resources::enums::standard_entry_class_code::StandardEntryClassCode;
3use serde::{Deserialize, Serialize};
4use serde_with::skip_serializing_none;
5
6#[skip_serializing_none]
7#[derive(Clone, Debug, Default, Deserialize, Serialize)]
8pub struct PaymentMethod {
9    /// The merchant-preferred payment methods.
10    ///
11    /// The possible values are:
12    ///
13    /// - UNRESTRICTED. Accepts any type of payment from the customer.
14    /// - IMMEDIATE_PAYMENT_REQUIRED. Accepts only immediate payment from the customer. For example, credit card, PayPal balance,
15    ///   or instant ACH. Ensures that at the time of capture, the payment does not have the `pending` status.
16    pub payee_preferred: Option<PayeePreferred>,
17
18    /// NACHA (the regulatory body governing the ACH network) requires that API callers (merchants, partners) obtain the consumer’s explicit
19    /// authorization before initiating a transaction. To stay compliant, you’ll need to make sure that you retain a compliant authorization
20    /// for each transaction that you originate to the ACH Network using this API. ACH transactions are categorized (using SEC codes) by how
21    /// you capture authorization from the Receiver (the person whose bank account is being debited or credited). PayPal supports the
22    /// following SEC codes.
23    ///
24    /// The possible values are:
25    ///
26    /// - TEL. The API caller (merchant/partner) accepts authorization and payment information from a consumer over the telephone.
27    /// - WEB. The API caller (merchant/partner) accepts Debit transactions from a consumer on their website.
28    /// - CCD. Cash concentration and disbursement for corporate debit transaction. Used to disburse or consolidate funds. Entries are
29    ///   usually Optional high-dollar, low-volume, and time-critical. (e.g. intra-company transfers or invoice payments to suppliers).
30    /// - PPD. Prearranged payment and deposit entries. Used for debit payments authorized by a consumer account holder, and usually
31    ///   initiated by a company. These are usually recurring debits (such as insurance premiums).
32    pub standard_entry_class_code: Option<StandardEntryClassCode>,
33}