diff --git a/openapi/version.json b/openapi/version.json index f166353cc..8f4c5116b 100644 --- a/openapi/version.json +++ b/openapi/version.json @@ -1,3 +1,3 @@ { - "version": "v516" + "version": "v532" } \ No newline at end of file diff --git a/src/resources/generated/api_errors.rs b/src/resources/generated/api_errors.rs index 6ab81205d..f88ec543f 100644 --- a/src/resources/generated/api_errors.rs +++ b/src/resources/generated/api_errors.rs @@ -213,6 +213,7 @@ pub enum ApiErrorsCode { SkuInactive, StateUnsupported, StatusTransitionInvalid, + StripeTaxInactive, TaxIdInvalid, TaxesCalculationFailed, TerminalLocationCountryUnsupported, @@ -412,6 +413,7 @@ impl ApiErrorsCode { ApiErrorsCode::SkuInactive => "sku_inactive", ApiErrorsCode::StateUnsupported => "state_unsupported", ApiErrorsCode::StatusTransitionInvalid => "status_transition_invalid", + ApiErrorsCode::StripeTaxInactive => "stripe_tax_inactive", ApiErrorsCode::TaxIdInvalid => "tax_id_invalid", ApiErrorsCode::TaxesCalculationFailed => "taxes_calculation_failed", ApiErrorsCode::TerminalLocationCountryUnsupported => { diff --git a/src/resources/generated/balance.rs b/src/resources/generated/balance.rs index 8dae5e112..d1a4232e8 100644 --- a/src/resources/generated/balance.rs +++ b/src/resources/generated/balance.rs @@ -12,18 +12,18 @@ use crate::resources::Currency; /// For more details see #[derive(Clone, Debug, Default, Deserialize, Serialize)] pub struct Balance { - /// Funds that are available to be transferred or paid out, whether automatically by Stripe or explicitly via the [Transfers API](https://stripe.com/docs/api#transfers) or [Payouts API](https://stripe.com/docs/api#payouts). + /// Available funds that you can transfer or pay out automatically by Stripe or explicitly through the [Transfers API](https://stripe.com/docs/api#transfers) or [Payouts API](https://stripe.com/docs/api#payouts). /// - /// The available balance for each currency and payment type can be found in the `source_types` property. + /// You can find the available balance for each currency and payment type in the `source_types` property. pub available: Vec, /// Funds held due to negative balances on connected Custom accounts. /// - /// The connect reserve balance for each currency and payment type can be found in the `source_types` property. + /// You can find the connect reserve balance for each currency and payment type in the `source_types` property. #[serde(skip_serializing_if = "Option::is_none")] pub connect_reserved: Option>, - /// Funds that can be paid out using Instant Payouts. + /// Funds that you can pay out using Instant Payouts. #[serde(skip_serializing_if = "Option::is_none")] pub instant_available: Option>, @@ -33,9 +33,9 @@ pub struct Balance { /// Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. pub livemode: bool, - /// Funds that are not yet available in the balance. + /// Funds that aren't available in the balance yet. /// - /// The pending balance for each currency, and for each payment type, can be found in the `source_types` property. + /// You can find the pending balance for each currency and each payment type in the `source_types` property. pub pending: Vec, } diff --git a/src/resources/generated/balance_transaction.rs b/src/resources/generated/balance_transaction.rs index e562bd7b3..24ea5ba91 100644 --- a/src/resources/generated/balance_transaction.rs +++ b/src/resources/generated/balance_transaction.rs @@ -19,10 +19,10 @@ pub struct BalanceTransaction { /// Unique identifier for the object. pub id: BalanceTransactionId, - /// Gross amount of the transaction, in cents (or local equivalent). + /// Gross amount of the transaction (in cents (or local equivalent)). pub amount: i64, - /// The date the transaction's net funds will become available in the Stripe balance. + /// The date that the transaction's net funds become available in the Stripe balance. pub available_on: Timestamp, /// Time at which the object was created. @@ -40,13 +40,11 @@ pub struct BalanceTransaction { /// Often useful for displaying to users. pub description: Option, - /// The exchange rate used, if applicable, for this transaction. + /// If applicable, this transaction uses an exchange rate. /// - /// Specifically, if money was converted from currency A to currency B, then the `amount` in currency A, times `exchange_rate`, would be the `amount` in currency B. - /// For example, suppose you charged a customer 10.00 EUR. - /// Then the PaymentIntent's `amount` would be `1000` and `currency` would be `eur`. - /// Suppose this was converted into 12.34 USD in your Stripe account. - /// Then the BalanceTransaction's `amount` would be `1234`, `currency` would be `usd`, and `exchange_rate` would be `1.234`. + /// If money converts from currency A to currency B, then the `amount` in currency A, multipled by the `exchange_rate`, equals the `amount` in currency B. + /// For example, if you charge a customer 10.00 EUR, the PaymentIntent's `amount` is `1000` and `currency` is `eur`. + /// If this converts to 12.34 USD in your Stripe account, the BalanceTransaction's `amount` is `1234`, its `currency` is `usd`, and the `exchange_rate` is `1.234`. pub exchange_rate: Option, /// Fees (in cents (or local equivalent)) paid for this transaction. @@ -55,24 +53,22 @@ pub struct BalanceTransaction { /// Detailed breakdown of fees (in cents (or local equivalent)) paid for this transaction. pub fee_details: Vec, - /// Net amount of the transaction, in cents (or local equivalent). + /// Net amount of the transaction (in cents (or local equivalent)). pub net: i64, - /// [Learn more](https://stripe.com/docs/reports/reporting-categories) about how reporting categories can help you understand balance transactions from an accounting perspective. + /// Learn more about how [reporting categories] (https://stripe.com/docs/reports/reporting-categories) can help you understand balance transactions from an accounting perspective. pub reporting_category: String, - /// The Stripe object to which this transaction is related. + /// This transaction relates to the Stripe object. pub source: Option>, - /// If the transaction's net funds are available in the Stripe balance yet. - /// - /// Either `available` or `pending`. + /// The transaction's net funds status in the Stripe balance, which are either `available` or `pending`. pub status: BalanceTransactionStatus, /// Transaction type: `adjustment`, `advance`, `advance_funding`, `anticipation_repayment`, `application_fee`, `application_fee_refund`, `charge`, `connect_collection_transfer`, `contribution`, `issuing_authorization_hold`, `issuing_authorization_release`, `issuing_dispute`, `issuing_transaction`, `obligation_inbound`, `obligation_outbound`, `obligation_reversal_inbound`, `obligation_reversal_outbound`, `obligation_payout`, `obligation_payout_failure`, `payment`, `payment_failure_refund`, `payment_refund`, `payment_reversal`, `payout`, `payout_cancel`, `payout_failure`, `refund`, `refund_failure`, `reserve_transaction`, `reserved_funds`, `stripe_fee`, `stripe_fx_fee`, `tax_fee`, `topup`, `topup_reversal`, `transfer`, `transfer_cancel`, `transfer_failure`, or `transfer_refund`. /// - /// [Learn more](https://stripe.com/docs/reports/balance-transaction-types) about balance transaction types and what they represent. - /// If you are looking to classify transactions for accounting purposes, you might want to consider `reporting_category` instead. + /// Learn more about [balance transaction types and what they represent](https://stripe.com/docs/reports/balance-transaction-types). + /// To classify transactions for accounting purposes, consider `reporting_category` instead. #[serde(rename = "type")] pub type_: BalanceTransactionType, } diff --git a/src/resources/generated/checkout_session.rs b/src/resources/generated/checkout_session.rs index 91edf4043..7e4dc9b4e 100644 --- a/src/resources/generated/checkout_session.rs +++ b/src/resources/generated/checkout_session.rs @@ -5,13 +5,17 @@ use serde::{Deserialize, Serialize}; use crate::client::{Client, Response}; -use crate::ids::{CheckoutSessionId, CustomerId, PaymentIntentId, PaymentLinkId, SubscriptionId}; +use crate::ids::{ + CheckoutSessionId, CustomerId, PaymentIntentId, PaymentLinkId, PaymentMethodConfigurationId, + SubscriptionId, +}; use crate::params::{ CurrencyMap, Expand, Expandable, List, Metadata, Object, Paginable, Timestamp, }; use crate::resources::{ Address, CheckoutSessionItem, Currency, Customer, Discount, Invoice, InvoiceSettingRenderingOptions, LinkedAccountOptionsUsBankAccount, PaymentIntent, PaymentLink, + PaymentMethodConfigBizPaymentMethodConfigurationDetails, PaymentMethodOptionsCustomerBalanceEuBankAccount, SetupIntent, Shipping, ShippingRate, Subscription, TaxId, TaxRate, }; @@ -136,6 +140,11 @@ pub struct CheckoutSession { /// Configure whether a Checkout Session should collect a payment method. pub payment_method_collection: Option, + /// Information about the payment method configuration used for this Checkout session if using dynamic payment methods. + #[serde(skip_serializing_if = "Option::is_none")] + pub payment_method_configuration_details: + Option, + /// Payment-method-specific configuration for the PaymentIntent or SetupIntent of this CheckoutSession. pub payment_method_options: Option, @@ -1193,6 +1202,10 @@ pub struct CreateCheckoutSession<'a> { #[serde(skip_serializing_if = "Option::is_none")] pub payment_method_collection: Option, + /// The ID of the payment method configuration to use with this Checkout session. + #[serde(skip_serializing_if = "Option::is_none")] + pub payment_method_configuration: Option, + /// Payment-method-specific configuration. #[serde(skip_serializing_if = "Option::is_none")] pub payment_method_options: Option, @@ -1283,6 +1296,7 @@ impl<'a> CreateCheckoutSession<'a> { mode: Default::default(), payment_intent_data: Default::default(), payment_method_collection: Default::default(), + payment_method_configuration: Default::default(), payment_method_options: Default::default(), payment_method_types: Default::default(), phone_number_collection: Default::default(), diff --git a/src/resources/generated/customer.rs b/src/resources/generated/customer.rs index 28b32b713..7e75377fa 100644 --- a/src/resources/generated/customer.rs +++ b/src/resources/generated/customer.rs @@ -26,19 +26,20 @@ pub struct Customer { #[serde(skip_serializing_if = "Option::is_none")] pub address: Option
, - /// Current balance, if any, being stored on the customer. + /// The current balance, if any, that's stored on the customer. /// /// If negative, the customer has credit to apply to their next invoice. - /// If positive, the customer has an amount owed that will be added to their next invoice. - /// The balance does not refer to any unpaid invoices; it solely takes into account amounts that have yet to be successfully applied to any invoice. - /// This balance is only taken into account as invoices are finalized. + /// If positive, the customer has an amount owed that's added to their next invoice. + /// The balance only considers amounts that Stripe hasn't successfully applied to any invoice. + /// It doesn't reflect unpaid invoices. + /// This balance is only taken into account after invoices finalize. #[serde(skip_serializing_if = "Option::is_none")] pub balance: Option, /// The current funds being held by Stripe on behalf of the customer. /// - /// These funds can be applied towards payment intents with source "cash_balance". - /// The settings[reconciliation_mode] field describes whether these funds are applied to such payment intents manually or automatically. + /// You can apply these funds towards payment intents when the source is "cash_balance". + /// The `settings[reconciliation_mode]` field describes if these funds apply to these payment intents manually or automatically. #[serde(skip_serializing_if = "Option::is_none")] pub cash_balance: Option, @@ -54,7 +55,7 @@ pub struct Customer { /// ID of the default payment source for the customer. /// - /// If you are using payment methods created via the PaymentMethods API, see the [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) field instead. + /// If you use payment methods created through the PaymentMethods API, see the [invoice_settings.default_payment_method](https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method) field instead. #[serde(skip_serializing_if = "Option::is_none")] pub default_source: Option>, @@ -62,9 +63,9 @@ pub struct Customer { #[serde(default)] pub deleted: bool, - /// When the customer's latest invoice is billed by charging automatically, `delinquent` is `true` if the invoice's latest charge failed. + /// If Stripe bills the customer's latest invoice by automatically charging and the latest charge fails, it sets `delinquent`` to `true``. /// - /// When the customer's latest invoice is billed by sending an invoice, `delinquent` is `true` if the invoice isn't paid by its due date. If an invoice is marked uncollectible by [dunning](https://stripe.com/docs/billing/automatic-collection), `delinquent` doesn't get reset to `false`. + /// If Stripe bills the invoice by sending it, and the invoice isn't paid by the due date, it also sets `delinquent`` to `true`. If an invoice becomes uncollectible by [dunning](https://stripe.com/docs/billing/automatic-collection), `delinquent` doesn't reset to `false`. #[serde(skip_serializing_if = "Option::is_none")] pub delinquent: Option, @@ -82,13 +83,13 @@ pub struct Customer { #[serde(skip_serializing_if = "Option::is_none")] pub email: Option, - /// The current multi-currency balances, if any, being stored on the customer. + /// The current multi-currency balances, if any, that's stored on the customer. /// /// If positive in a currency, the customer has a credit to apply to their next invoice denominated in that currency. - /// If negative, the customer has an amount owed that will be added to their next invoice denominated in that currency. - /// These balances do not refer to any unpaid invoices. - /// They solely track amounts that have yet to be successfully applied to any invoice. - /// A balance in a particular currency is only applied to any invoice as an invoice in that currency is finalized. + /// If negative, the customer has an amount owed that's added to their next invoice denominated in that currency. + /// These balances don't apply to unpaid invoices. + /// They solely track amounts that Stripe hasn't successfully applied to any invoice. + /// Stripe only applies a balance in a specific currency to an invoice after that invoice (which is in the same currency) finalizes. #[serde(skip_serializing_if = "Option::is_none")] pub invoice_credit_balance: Option, @@ -113,7 +114,7 @@ pub struct Customer { #[serde(skip_serializing_if = "Option::is_none")] pub name: Option, - /// The suffix of the customer's next invoice number, e.g., 0001. + /// The suffix of the customer's next invoice number (for example, 0001). #[serde(skip_serializing_if = "Option::is_none")] pub next_invoice_sequence: Option, @@ -142,10 +143,9 @@ pub struct Customer { #[serde(skip_serializing_if = "Option::is_none")] pub tax: Option, - /// Describes the customer's tax exemption status. + /// Describes the customer's tax exemption status, which is `none`, `exempt`, or `reverse`. /// - /// One of `none`, `exempt`, or `reverse`. - /// When set to `reverse`, invoice and receipt PDFs include the text **"Reverse charge"**. + /// When set to `reverse`, invoice and receipt PDFs include the following text: **"Reverse charge"**. #[serde(skip_serializing_if = "Option::is_none")] pub tax_exempt: Option, @@ -153,7 +153,7 @@ pub struct Customer { #[serde(default)] pub tax_ids: List, - /// ID of the test clock this customer belongs to. + /// ID of the test clock that this customer belongs to. #[serde(skip_serializing_if = "Option::is_none")] pub test_clock: Option>, } diff --git a/src/resources/generated/dispute.rs b/src/resources/generated/dispute.rs index 348b35f2d..129291a98 100644 --- a/src/resources/generated/dispute.rs +++ b/src/resources/generated/dispute.rs @@ -19,13 +19,13 @@ pub struct Dispute { /// Disputed amount. /// - /// Usually the amount of the charge, but can differ (usually because of currency fluctuation or because only part of the order is disputed). + /// Usually the amount of the charge, but it can differ (usually because of currency fluctuation or because only part of the order is disputed). pub amount: i64, /// List of zero, one, or two balance transactions that show funds withdrawn and reinstated to your Stripe account as a result of this dispute. pub balance_transactions: Vec, - /// ID of the charge that was disputed. + /// ID of the charge that's disputed. pub charge: Expandable, /// Time at which the object was created. @@ -42,9 +42,9 @@ pub struct Dispute { pub evidence_details: DisputeEvidenceDetails, - /// If true, it is still possible to refund the disputed payment. + /// If true, it's still possible to refund the disputed payment. /// - /// Once the payment has been fully refunded, no further funds will be withdrawn from your Stripe account as a result of this dispute. + /// After the payment has been fully refunded, no further funds are withdrawn from your Stripe account as a result of this dispute. pub is_charge_refundable: bool, /// Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. @@ -59,7 +59,7 @@ pub struct Dispute { #[serde(skip_serializing_if = "Option::is_none")] pub network_reason_code: Option, - /// ID of the PaymentIntent that was disputed. + /// ID of the PaymentIntent that's disputed. pub payment_intent: Option>, #[serde(skip_serializing_if = "Option::is_none")] @@ -68,7 +68,7 @@ pub struct Dispute { /// Reason given by cardholder for dispute. /// /// Possible values are `bank_cannot_process`, `check_returned`, `credit_not_processed`, `customer_initiated`, `debit_not_authorized`, `duplicate`, `fraudulent`, `general`, `incorrect_account_details`, `insufficient_funds`, `product_not_received`, `product_unacceptable`, `subscription_canceled`, or `unrecognized`. - /// Read more about [dispute reasons](https://stripe.com/docs/disputes/categories). + /// Learn more about [dispute reasons](https://stripe.com/docs/disputes/categories). pub reason: String, /// Current status of dispute. diff --git a/src/resources/generated/ephemeral_key.rs b/src/resources/generated/ephemeral_key.rs index d427f678d..a9ee6c0fc 100644 --- a/src/resources/generated/ephemeral_key.rs +++ b/src/resources/generated/ephemeral_key.rs @@ -71,6 +71,10 @@ pub struct CreateEphemeralKey<'a> { #[serde(skip_serializing_if = "Option::is_none")] pub issuing_card: Option, + /// A single-use token, created by Stripe.js, used for creating ephemeral keys for Issuing Cards without exchanging sensitive information. + #[serde(skip_serializing_if = "Option::is_none")] + pub nonce: Option<&'a str>, + /// The ID of the Identity VerificationSession you'd like to access using the resulting ephemeral key. #[serde(skip_serializing_if = "Option::is_none")] pub verification_session: Option<&'a str>, @@ -82,6 +86,7 @@ impl<'a> CreateEphemeralKey<'a> { customer: Default::default(), expand: Default::default(), issuing_card: Default::default(), + nonce: Default::default(), verification_session: Default::default(), } } diff --git a/src/resources/generated/event.rs b/src/resources/generated/event.rs index ab2d0e79c..a3a85e112 100644 --- a/src/resources/generated/event.rs +++ b/src/resources/generated/event.rs @@ -17,13 +17,13 @@ pub struct Event { /// Unique identifier for the object. pub id: EventId, - /// The connected account that originated the event. + /// The connected account that originates the event. #[serde(skip_serializing_if = "Option::is_none")] pub account: Option, /// The Stripe API version used to render `data`. /// - /// *Note: This property is populated only for events on or after October 31, 2014*. + /// This property is populated only for events on or after October 31, 2014. pub api_version: Option, /// Time at which the object was created. @@ -36,13 +36,13 @@ pub struct Event { /// Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. pub livemode: bool, - /// Number of webhooks that have yet to be successfully delivered (i.e., to return a 20x response) to the URLs you've specified. + /// Number of webhooks that haven't been successfully delivered (for example, to return a 20x response) to the URLs you specify. pub pending_webhooks: i64, - /// Information on the API request that instigated the event. + /// Information on the API request that triggers the event. pub request: Option, - /// Description of the event (e.g., `invoice.created` or `charge.refunded`). + /// Description of the event (for example, `invoice.created` or `charge.refunded`). #[serde(rename = "type")] pub type_: EventType, } diff --git a/src/resources/generated/issuing_authorization_amount_details.rs b/src/resources/generated/issuing_authorization_amount_details.rs index 973e1db10..17e92a082 100644 --- a/src/resources/generated/issuing_authorization_amount_details.rs +++ b/src/resources/generated/issuing_authorization_amount_details.rs @@ -10,4 +10,7 @@ pub struct IssuingAuthorizationAmountDetails { /// The fee charged by the ATM for the cash withdrawal. pub atm_fee: Option, + + /// The amount of cash requested by the cardholder. + pub cashback_amount: Option, } diff --git a/src/resources/generated/issuing_card.rs b/src/resources/generated/issuing_card.rs index 24dd600d2..87f07660d 100644 --- a/src/resources/generated/issuing_card.rs +++ b/src/resources/generated/issuing_card.rs @@ -149,9 +149,10 @@ pub struct IssuingCardShipping { /// Recipient name. pub name: String, - /// The phone number of the receiver of the bulk shipment. + /// The phone number of the receiver of the shipment. /// - /// This phone number will be provided to the shipping company, who might use it to contact the receiver in case of delivery issues. + /// Our courier partners will use this number to contact you in the event of card delivery issues. + /// For individual shipments to the EU/UK, if this field is empty, we will provide them with the phone number provided when the cardholder was initially created. pub phone_number: Option, /// Whether a signature is required for card delivery. diff --git a/src/resources/generated/issuing_transaction.rs b/src/resources/generated/issuing_transaction.rs index 60c061c73..f4c947b6a 100644 --- a/src/resources/generated/issuing_transaction.rs +++ b/src/resources/generated/issuing_transaction.rs @@ -103,6 +103,9 @@ impl Object for IssuingTransaction { pub struct IssuingTransactionAmountDetails { /// The fee charged by the ATM for the cash withdrawal. pub atm_fee: Option, + + /// The amount of cash requested by the cardholder. + pub cashback_amount: Option, } #[derive(Clone, Debug, Default, Deserialize, Serialize)] diff --git a/src/resources/generated/payment_intent.rs b/src/resources/generated/payment_intent.rs index 6808e1ef4..6dcc22700 100644 --- a/src/resources/generated/payment_intent.rs +++ b/src/resources/generated/payment_intent.rs @@ -5,13 +5,17 @@ use serde::{Deserialize, Serialize}; use crate::client::{Client, Response}; -use crate::ids::{CustomerId, MandateId, PaymentIntentId, PaymentMethodId}; +use crate::ids::{ + CustomerId, MandateId, PaymentIntentId, PaymentMethodConfigurationId, PaymentMethodId, +}; use crate::params::{Expand, Expandable, List, Metadata, Object, Paginable, RangeQuery, Timestamp}; use crate::resources::{ Account, ApiErrors, Application, Charge, Currency, Customer, Invoice, LinkedAccountOptionsUsBankAccount, PaymentIntentNextActionCashappHandleRedirectOrDisplayQrCode, - PaymentIntentOffSession, PaymentMethod, PaymentMethodDetailsCardInstallmentsPlan, - PaymentMethodOptionsCustomerBalanceEuBankAccount, PaymentSource, Review, Shipping, + PaymentIntentOffSession, PaymentMethod, + PaymentMethodConfigBizPaymentMethodConfigurationDetails, + PaymentMethodDetailsCardInstallmentsPlan, PaymentMethodOptionsCustomerBalanceEuBankAccount, + PaymentSource, Review, Shipping, }; /// The resource representing a Stripe "PaymentIntent". @@ -125,6 +129,11 @@ pub struct PaymentIntent { /// ID of the payment method used in this PaymentIntent. pub payment_method: Option>, + /// Information about the payment method configuration used for this PaymentIntent. + #[serde(skip_serializing_if = "Option::is_none")] + pub payment_method_configuration_details: + Option, + /// Payment-method-specific configuration for this PaymentIntent. pub payment_method_options: Option, @@ -1555,6 +1564,10 @@ pub struct CreatePaymentIntent<'a> { #[serde(skip_serializing_if = "Option::is_none")] pub payment_method: Option, + /// The ID of the payment method configuration to use with this PaymentIntent. + #[serde(skip_serializing_if = "Option::is_none")] + pub payment_method_configuration: Option, + /// If provided, this hash will be used to create a PaymentMethod. /// /// The new PaymentMethod will appear in the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method) property on the PaymentIntent. @@ -1653,6 +1666,7 @@ impl<'a> CreatePaymentIntent<'a> { off_session: Default::default(), on_behalf_of: Default::default(), payment_method: Default::default(), + payment_method_configuration: Default::default(), payment_method_data: Default::default(), payment_method_options: Default::default(), payment_method_types: Default::default(), @@ -1784,6 +1798,10 @@ pub struct UpdatePaymentIntent<'a> { #[serde(skip_serializing_if = "Option::is_none")] pub payment_method: Option, + /// The ID of the payment method configuration to use with this PaymentIntent. + #[serde(skip_serializing_if = "Option::is_none")] + pub payment_method_configuration: Option, + /// If provided, this hash will be used to create a PaymentMethod. /// /// The new PaymentMethod will appear in the [payment_method](https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method) property on the PaymentIntent. @@ -1858,6 +1876,7 @@ impl<'a> UpdatePaymentIntent<'a> { expand: Default::default(), metadata: Default::default(), payment_method: Default::default(), + payment_method_configuration: Default::default(), payment_method_data: Default::default(), payment_method_options: Default::default(), payment_method_types: Default::default(), diff --git a/src/resources/generated/payment_method_config_biz_payment_method_configuration_details.rs b/src/resources/generated/payment_method_config_biz_payment_method_configuration_details.rs new file mode 100644 index 000000000..e6a7c52e1 --- /dev/null +++ b/src/resources/generated/payment_method_config_biz_payment_method_configuration_details.rs @@ -0,0 +1,13 @@ +// ====================================== +// This file was automatically generated. +// ====================================== + +use serde::{Deserialize, Serialize}; + +/// The resource representing a Stripe "PaymentMethodConfigBizPaymentMethodConfigurationDetails". +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct PaymentMethodConfigBizPaymentMethodConfigurationDetails { + + /// ID of the parent payment method configuration used. + pub parent: Option, +} diff --git a/src/resources/generated/payment_method_configuration.rs b/src/resources/generated/payment_method_configuration.rs new file mode 100644 index 000000000..a0a1859dc --- /dev/null +++ b/src/resources/generated/payment_method_configuration.rs @@ -0,0 +1,4198 @@ +// ====================================== +// This file was automatically generated. +// ====================================== + +use crate::client::{Client, Response}; +use crate::ids::{PaymentMethodConfigurationId}; +use crate::params::{Expand, List, Object, Paginable}; +use serde::{Deserialize, Serialize}; + +/// The resource representing a Stripe "PaymentMethodConfigResourcePaymentMethodConfiguration". +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct PaymentMethodConfiguration { + /// Unique identifier for the object. + pub id: PaymentMethodConfigurationId, + + #[serde(skip_serializing_if = "Option::is_none")] + pub acss_debit: Option, + + /// Whether the configuration can be used for new payments. + pub active: bool, + + #[serde(skip_serializing_if = "Option::is_none")] + pub affirm: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub afterpay_clearpay: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub alipay: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub apple_pay: Option, + + /// The Connect application associated with this configuration. + pub application: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub au_becs_debit: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub bacs_debit: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub bancontact: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub blik: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub boleto: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub card: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub cartes_bancaires: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub cashapp: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub eps: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub fpx: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub giropay: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub google_pay: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub grabpay: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub id_bank_transfer: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub ideal: Option, + + /// The default configuration is used whenever no payment method configuration is specified. + pub is_default: bool, + + #[serde(skip_serializing_if = "Option::is_none")] + pub jcb: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub klarna: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub konbini: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub link: Option, + + /// Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. + pub livemode: bool, + + #[serde(skip_serializing_if = "Option::is_none")] + pub multibanco: Option, + + /// Configuration name. + pub name: String, + + #[serde(skip_serializing_if = "Option::is_none")] + pub netbanking: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub oxxo: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub p24: Option, + + /// The configuration's parent configuration. + pub parent: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub pay_by_bank: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub paynow: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub paypal: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub promptpay: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub sepa_debit: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub sofort: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub upi: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub us_bank_account: Option, + + #[serde(skip_serializing_if = "Option::is_none")] + pub wechat_pay: Option, +} + +impl PaymentMethodConfiguration { + + /// List payment method configurations. +pub fn list(client: &Client, params: &ListPaymentMethodConfigurations<'_>) -> Response> { + client.get_query("/payment_method_configurations", ¶ms) +} + + + /// Creates a payment method configuration. + pub fn create(client: &Client, params: CreatePaymentMethodConfiguration<'_>) -> Response { + client.post_form("/payment_method_configurations", ¶ms) + } + + /// Retrieve payment method configuration. + pub fn retrieve(client: &Client, id: &PaymentMethodConfigurationId, expand: &[&str]) -> Response { + client.get_query(&format!("/payment_method_configurations/{}", id), &Expand { expand }) + } + + /// Update payment method configuration. + pub fn update(client: &Client, id: &PaymentMethodConfigurationId, params: UpdatePaymentMethodConfiguration<'_>) -> Response { + client.post_form(&format!("/payment_method_configurations/{}", id), ¶ms) + } +} + +impl Object for PaymentMethodConfiguration { + type Id = PaymentMethodConfigurationId; + fn id(&self) -> Self::Id { + self.id.clone() + } + fn object(&self) -> &'static str { + "payment_method_configuration" + } +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct PaymentMethodConfigResourcePaymentMethodProperties { + + /// Whether this payment method may be offered at checkout. + /// + /// True if `display_preference` is `on` and the payment method's capability is active. + pub available: bool, + + pub display_preference: PaymentMethodConfigResourceDisplayPreference, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct PaymentMethodConfigResourceDisplayPreference { + + /// For child configurations, whether or not the account's preference will be observed. + /// + /// If `false`, the parent configuration's preference is used. + pub overridable: Option, + + /// The account's display preference. + pub preference: PaymentMethodConfigResourceDisplayPreferencePreference, + + /// The effective display preference value. + pub value: PaymentMethodConfigResourceDisplayPreferenceValue, +} + +/// The parameters for `PaymentMethodConfiguration::create`. +#[derive(Clone, Debug, Serialize, Default)] +pub struct CreatePaymentMethodConfiguration<'a> { + + /// Canadian pre-authorized debit payments, check this [page](https://stripe.com/docs/payments/acss-debit) for more details like country availability. + #[serde(skip_serializing_if = "Option::is_none")] + pub acss_debit: Option, + + /// [Affirm](https://www.affirm.com/) gives your customers a way to split purchases over a series of payments. + /// + /// Depending on the purchase, they can pay with four interest-free payments (Split Pay) or pay over a longer term (Installments), which might include interest. + /// Check this [page](https://stripe.com/docs/payments/affirm) for more details like country availability. + #[serde(skip_serializing_if = "Option::is_none")] + pub affirm: Option, + + /// Afterpay gives your customers a way to pay for purchases in installments, check this [page](https://stripe.com/docs/payments/afterpay-clearpay) for more details like country availability. + /// + /// Afterpay is particularly popular among businesses selling fashion, beauty, and sports products. + #[serde(skip_serializing_if = "Option::is_none")] + pub afterpay_clearpay: Option, + + /// Alipay is a digital wallet in China that has more than a billion active users worldwide. + /// + /// Alipay users can pay on the web or on a mobile device using login credentials or their Alipay app. + /// Alipay has a low dispute rate and reduces fraud by authenticating payments using the customer's login credentials. + /// Check this [page](https://stripe.com/docs/payments/alipay) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub alipay: Option, + + /// Stripe users can accept [Apple Pay](/payments/apple-pay) in iOS applications in iOS 9 and later, and on the web in Safari starting with iOS 10 or macOS Sierra. + /// + /// There are no additional fees to process Apple Pay payments, and the [pricing](/pricing) is the same as other card transactions. + /// Check this [page](https://stripe.com/docs/apple-pay) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub apple_pay: Option, + + /// Apple Pay Later, a payment method for customers to buy now and pay later, gives your customers a way to split purchases into four installments across six weeks. + #[serde(skip_serializing_if = "Option::is_none")] + pub apple_pay_later: Option, + + /// Stripe users in Australia can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with an Australian bank account. + /// + /// Check this [page](https://stripe.com/docs/payments/au-becs-debit) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub au_becs_debit: Option, + + /// Stripe users in the UK can accept Bacs Direct Debit payments from customers with a UK bank account, check this [page](https://stripe.com/docs/payments/payment-methods/bacs-debit) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub bacs_debit: Option, + + /// Bancontact is the most popular online payment method in Belgium, with over 15 million cards in circulation. + /// + /// [Customers](https://stripe.com/docs/api/customers) use a Bancontact card or mobile app linked to a Belgian bank account to make online payments that are secure, guaranteed, and confirmed immediately. + /// Check this [page](https://stripe.com/docs/payments/bancontact) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub bancontact: Option, + + /// BLIK is a [single use](https://stripe.com/docs/payments/payment-methods#usage) payment method that requires customers to authenticate their payments. + /// + /// When customers want to pay online using BLIK, they request a six-digit code from their banking application and enter it into the payment collection form. + /// Check this [page](https://stripe.com/docs/payments/blik) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub blik: Option, + + /// Boleto is an official (regulated by the Central Bank of Brazil) payment method in Brazil. + /// + /// Check this [page](https://stripe.com/docs/payments/boleto) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub boleto: Option, + + /// Cards are a popular way for consumers and businesses to pay online or in person. + /// + /// Stripe supports global and local card networks. + #[serde(skip_serializing_if = "Option::is_none")] + pub card: Option, + + /// Cartes Bancaires is France's local card network. + /// + /// More than 95% of these cards are co-branded with either Visa or Mastercard, meaning you can process these cards over either Cartes Bancaires or the Visa or Mastercard networks. + /// Check this [page](https://stripe.com/docs/payments/cartes-bancaires) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub cartes_bancaires: Option, + + /// Cash App is a popular consumer app in the US that allows customers to bank, invest, send, and receive money using their digital wallet. + /// + /// Check this [page](https://stripe.com/docs/payments/cash-app-pay) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub cashapp: Option, + + /// EPS is an Austria-based payment method that allows customers to complete transactions online using their bank credentials. + /// + /// EPS is supported by all Austrian banks and is accepted by over 80% of Austrian online retailers. + /// Check this [page](https://stripe.com/docs/payments/eps) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub eps: Option, + + /// Specifies which fields in the response should be expanded. + #[serde(skip_serializing_if = "Expand::is_empty")] + pub expand: &'a [&'a str], + + /// Financial Process Exchange (FPX) is a Malaysia-based payment method that allows customers to complete transactions online using their bank credentials. + /// + /// Bank Negara Malaysia (BNM), the Central Bank of Malaysia, and eleven other major Malaysian financial institutions are members of the PayNet Group, which owns and operates FPX. + /// It is one of the most popular online payment methods in Malaysia, with nearly 90 million transactions in 2018 according to BNM. + /// Check this [page](https://stripe.com/docs/payments/fpx) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub fpx: Option, + + /// giropay is a German payment method based on online banking, introduced in 2006. + /// + /// It allows customers to complete transactions online using their online banking environment, with funds debited from their bank account. + /// Depending on their bank, customers confirm payments on giropay using a second factor of authentication or a PIN. + /// giropay accounts for 10% of online checkouts in Germany. + /// Check this [page](https://stripe.com/docs/payments/giropay) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub giropay: Option, + + /// Google Pay allows customers to make payments in your app or website using any credit or debit card saved to their Google Account, including those from Google Play, YouTube, Chrome, or an Android device. + /// + /// Use the Google Pay API to request any credit or debit card stored in your customer's Google account. + /// Check this [page](https://stripe.com/docs/google-pay) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub google_pay: Option, + + /// GrabPay is a payment method developed by [Grab](https://www.grab.com/sg/consumer/finance/pay/). + /// + /// GrabPay is a digital wallet - customers maintain a balance in their wallets that they pay out with. + /// Check this [page](https://stripe.com/docs/payments/grabpay) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub grabpay: Option, + + /// iDEAL is a Netherlands-based payment method that allows customers to complete transactions online using their bank credentials. + /// + /// All major Dutch banks are members of Currence, the scheme that operates iDEAL, making it the most popular online payment method in the Netherlands with a share of online transactions close to 55%. + /// Check this [page](https://stripe.com/docs/payments/ideal) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub ideal: Option, + + /// JCB is a credit card company based in Japan. + /// + /// JCB is currently available in Japan to businesses approved by JCB, and available to all businesses in the US, Canada, Australia, New Zealand, UK, and Ireland. + /// Check this [page](https://support.stripe.com/questions/accepting-japan-credit-bureau-%28jcb%29-payments) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub jcb: Option, + + /// Klarna gives customers a range of [payment options](https://stripe.com/docs/payments/klarna#payment-options) during checkout. + /// + /// Available payment options vary depending on the customer's billing address and the transaction amount. + /// These payment options make it convenient for customers to purchase items in all price ranges. + /// Check this [page](https://stripe.com/docs/payments/klarna) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub klarna: Option, + + /// Konbini allows customers in Japan to pay for bills and online purchases at convenience stores with cash. + /// + /// Check this [page](https://stripe.com/docs/payments/konbini) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub konbini: Option, + + /// [Link](https://stripe.com/docs/payments/link) is a payment method network. + /// + /// With Link, users save their payment details once, then reuse that information to pay with one click for any business on the network. + #[serde(skip_serializing_if = "Option::is_none")] + pub link: Option, + + /// Configuration name. + #[serde(skip_serializing_if = "Option::is_none")] + pub name: Option<&'a str>, + + /// OXXO is a Mexican chain of convenience stores with thousands of locations across Latin America and represents nearly 20% of online transactions in Mexico. + /// + /// OXXO allows customers to pay bills and online purchases in-store with cash. + /// Check this [page](https://stripe.com/docs/payments/oxxo) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub oxxo: Option, + + /// Przelewy24 is a Poland-based payment method aggregator that allows customers to complete transactions online using bank transfers and other methods. + /// + /// Bank transfers account for 30% of online payments in Poland and Przelewy24 provides a way for customers to pay with over 165 banks. + /// Check this [page](https://stripe.com/docs/payments/p24) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub p24: Option, + + /// Configuration's parent configuration. + /// + /// Specify to create a child configuration. + #[serde(skip_serializing_if = "Option::is_none")] + pub parent: Option<&'a str>, + + /// PayNow is a Singapore-based payment method that allows customers to make a payment using their preferred app from participating banks and participating non-bank financial institutions. + /// + /// Check this [page](https://stripe.com/docs/payments/paynow) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub paynow: Option, + + /// PayPal, a digital wallet popular with customers in Europe, allows your customers worldwide to pay using their PayPal account. + /// + /// Check this [page](https://stripe.com/docs/payments/paypal) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub paypal: Option, + + /// PromptPay is a Thailand-based payment method that allows customers to make a payment using their preferred app from participating banks. + /// + /// Check this [page](https://stripe.com/docs/payments/promptpay) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub promptpay: Option, + + /// The [Single Euro Payments Area (SEPA)](https://en.wikipedia.org/wiki/Single_Euro_Payments_Area) is an initiative of the European Union to simplify payments within and across member countries. + /// + /// SEPA established and enforced banking standards to allow for the direct debiting of every EUR-denominated bank account within the SEPA region, check this [page](https://stripe.com/docs/payments/sepa-debit) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub sepa_debit: Option, + + /// Stripe users in Europe and the United States can use the [Payment Intents API](https://stripe.com/docs/payments/payment-intents)—a single integration path for creating payments using any supported method—to accept [Sofort](https://www.sofort.com/) payments from customers. + /// + /// Check this [page](https://stripe.com/docs/payments/sofort) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub sofort: Option, + + /// Stripe users in the United States can accept ACH direct debit payments from customers with a US bank account using the Automated Clearing House (ACH) payments system operated by Nacha. + /// + /// Check this [page](https://stripe.com/docs/payments/ach-debit) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub us_bank_account: Option, + + /// WeChat, owned by Tencent, is China's leading mobile app with over 1 billion monthly active users. + /// + /// Chinese consumers can use WeChat Pay to pay for goods and services inside of businesses' apps and websites. + /// WeChat Pay users buy most frequently in gaming, e-commerce, travel, online education, and food/nutrition. + /// Check this [page](https://stripe.com/docs/payments/wechat-pay) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub wechat_pay: Option, +} + +impl<'a> CreatePaymentMethodConfiguration<'a> { + pub fn new() -> Self { + CreatePaymentMethodConfiguration { + acss_debit: Default::default(), + affirm: Default::default(), + afterpay_clearpay: Default::default(), + alipay: Default::default(), + apple_pay: Default::default(), + apple_pay_later: Default::default(), + au_becs_debit: Default::default(), + bacs_debit: Default::default(), + bancontact: Default::default(), + blik: Default::default(), + boleto: Default::default(), + card: Default::default(), + cartes_bancaires: Default::default(), + cashapp: Default::default(), + eps: Default::default(), + expand: Default::default(), + fpx: Default::default(), + giropay: Default::default(), + google_pay: Default::default(), + grabpay: Default::default(), + ideal: Default::default(), + jcb: Default::default(), + klarna: Default::default(), + konbini: Default::default(), + link: Default::default(), + name: Default::default(), + oxxo: Default::default(), + p24: Default::default(), + parent: Default::default(), + paynow: Default::default(), + paypal: Default::default(), + promptpay: Default::default(), + sepa_debit: Default::default(), + sofort: Default::default(), + us_bank_account: Default::default(), + wechat_pay: Default::default(), + } + } +} + +/// The parameters for `PaymentMethodConfiguration::list`. +#[derive(Clone, Debug, Serialize, Default)] +pub struct ListPaymentMethodConfigurations<'a> { + + /// The Connect application to filter by. + #[serde(skip_serializing_if = "Option::is_none")] + pub application: Option, + + /// Specifies which fields in the response should be expanded. + #[serde(skip_serializing_if = "Expand::is_empty")] + pub expand: &'a [&'a str], +} + +impl<'a> ListPaymentMethodConfigurations<'a> { + pub fn new() -> Self { + ListPaymentMethodConfigurations { + application: Default::default(), + expand: Default::default(), + } + } +} +impl Paginable for ListPaymentMethodConfigurations<'_> { + type O = PaymentMethodConfiguration; + fn set_last(&mut self, item: Self::O) { + self.starting_after = Some(item.id()); + }} +/// The parameters for `PaymentMethodConfiguration::update`. +#[derive(Clone, Debug, Serialize, Default)] +pub struct UpdatePaymentMethodConfiguration<'a> { + + /// Canadian pre-authorized debit payments, check this [page](https://stripe.com/docs/payments/acss-debit) for more details like country availability. + #[serde(skip_serializing_if = "Option::is_none")] + pub acss_debit: Option, + + /// Whether the configuration can be used for new payments. + #[serde(skip_serializing_if = "Option::is_none")] + pub active: Option, + + /// [Affirm](https://www.affirm.com/) gives your customers a way to split purchases over a series of payments. + /// + /// Depending on the purchase, they can pay with four interest-free payments (Split Pay) or pay over a longer term (Installments), which might include interest. + /// Check this [page](https://stripe.com/docs/payments/affirm) for more details like country availability. + #[serde(skip_serializing_if = "Option::is_none")] + pub affirm: Option, + + /// Afterpay gives your customers a way to pay for purchases in installments, check this [page](https://stripe.com/docs/payments/afterpay-clearpay) for more details like country availability. + /// + /// Afterpay is particularly popular among businesses selling fashion, beauty, and sports products. + #[serde(skip_serializing_if = "Option::is_none")] + pub afterpay_clearpay: Option, + + /// Alipay is a digital wallet in China that has more than a billion active users worldwide. + /// + /// Alipay users can pay on the web or on a mobile device using login credentials or their Alipay app. + /// Alipay has a low dispute rate and reduces fraud by authenticating payments using the customer's login credentials. + /// Check this [page](https://stripe.com/docs/payments/alipay) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub alipay: Option, + + /// Stripe users can accept [Apple Pay](/payments/apple-pay) in iOS applications in iOS 9 and later, and on the web in Safari starting with iOS 10 or macOS Sierra. + /// + /// There are no additional fees to process Apple Pay payments, and the [pricing](/pricing) is the same as other card transactions. + /// Check this [page](https://stripe.com/docs/apple-pay) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub apple_pay: Option, + + /// Apple Pay Later, a payment method for customers to buy now and pay later, gives your customers a way to split purchases into four installments across six weeks. + #[serde(skip_serializing_if = "Option::is_none")] + pub apple_pay_later: Option, + + /// Stripe users in Australia can accept Bulk Electronic Clearing System (BECS) direct debit payments from customers with an Australian bank account. + /// + /// Check this [page](https://stripe.com/docs/payments/au-becs-debit) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub au_becs_debit: Option, + + /// Stripe users in the UK can accept Bacs Direct Debit payments from customers with a UK bank account, check this [page](https://stripe.com/docs/payments/payment-methods/bacs-debit) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub bacs_debit: Option, + + /// Bancontact is the most popular online payment method in Belgium, with over 15 million cards in circulation. + /// + /// [Customers](https://stripe.com/docs/api/customers) use a Bancontact card or mobile app linked to a Belgian bank account to make online payments that are secure, guaranteed, and confirmed immediately. + /// Check this [page](https://stripe.com/docs/payments/bancontact) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub bancontact: Option, + + /// BLIK is a [single use](https://stripe.com/docs/payments/payment-methods#usage) payment method that requires customers to authenticate their payments. + /// + /// When customers want to pay online using BLIK, they request a six-digit code from their banking application and enter it into the payment collection form. + /// Check this [page](https://stripe.com/docs/payments/blik) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub blik: Option, + + /// Boleto is an official (regulated by the Central Bank of Brazil) payment method in Brazil. + /// + /// Check this [page](https://stripe.com/docs/payments/boleto) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub boleto: Option, + + /// Cards are a popular way for consumers and businesses to pay online or in person. + /// + /// Stripe supports global and local card networks. + #[serde(skip_serializing_if = "Option::is_none")] + pub card: Option, + + /// Cartes Bancaires is France's local card network. + /// + /// More than 95% of these cards are co-branded with either Visa or Mastercard, meaning you can process these cards over either Cartes Bancaires or the Visa or Mastercard networks. + /// Check this [page](https://stripe.com/docs/payments/cartes-bancaires) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub cartes_bancaires: Option, + + /// Cash App is a popular consumer app in the US that allows customers to bank, invest, send, and receive money using their digital wallet. + /// + /// Check this [page](https://stripe.com/docs/payments/cash-app-pay) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub cashapp: Option, + + /// EPS is an Austria-based payment method that allows customers to complete transactions online using their bank credentials. + /// + /// EPS is supported by all Austrian banks and is accepted by over 80% of Austrian online retailers. + /// Check this [page](https://stripe.com/docs/payments/eps) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub eps: Option, + + /// Specifies which fields in the response should be expanded. + #[serde(skip_serializing_if = "Expand::is_empty")] + pub expand: &'a [&'a str], + + /// Financial Process Exchange (FPX) is a Malaysia-based payment method that allows customers to complete transactions online using their bank credentials. + /// + /// Bank Negara Malaysia (BNM), the Central Bank of Malaysia, and eleven other major Malaysian financial institutions are members of the PayNet Group, which owns and operates FPX. + /// It is one of the most popular online payment methods in Malaysia, with nearly 90 million transactions in 2018 according to BNM. + /// Check this [page](https://stripe.com/docs/payments/fpx) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub fpx: Option, + + /// giropay is a German payment method based on online banking, introduced in 2006. + /// + /// It allows customers to complete transactions online using their online banking environment, with funds debited from their bank account. + /// Depending on their bank, customers confirm payments on giropay using a second factor of authentication or a PIN. + /// giropay accounts for 10% of online checkouts in Germany. + /// Check this [page](https://stripe.com/docs/payments/giropay) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub giropay: Option, + + /// Google Pay allows customers to make payments in your app or website using any credit or debit card saved to their Google Account, including those from Google Play, YouTube, Chrome, or an Android device. + /// + /// Use the Google Pay API to request any credit or debit card stored in your customer's Google account. + /// Check this [page](https://stripe.com/docs/google-pay) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub google_pay: Option, + + /// GrabPay is a payment method developed by [Grab](https://www.grab.com/sg/consumer/finance/pay/). + /// + /// GrabPay is a digital wallet - customers maintain a balance in their wallets that they pay out with. + /// Check this [page](https://stripe.com/docs/payments/grabpay) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub grabpay: Option, + + /// iDEAL is a Netherlands-based payment method that allows customers to complete transactions online using their bank credentials. + /// + /// All major Dutch banks are members of Currence, the scheme that operates iDEAL, making it the most popular online payment method in the Netherlands with a share of online transactions close to 55%. + /// Check this [page](https://stripe.com/docs/payments/ideal) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub ideal: Option, + + /// JCB is a credit card company based in Japan. + /// + /// JCB is currently available in Japan to businesses approved by JCB, and available to all businesses in the US, Canada, Australia, New Zealand, UK, and Ireland. + /// Check this [page](https://support.stripe.com/questions/accepting-japan-credit-bureau-%28jcb%29-payments) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub jcb: Option, + + /// Klarna gives customers a range of [payment options](https://stripe.com/docs/payments/klarna#payment-options) during checkout. + /// + /// Available payment options vary depending on the customer's billing address and the transaction amount. + /// These payment options make it convenient for customers to purchase items in all price ranges. + /// Check this [page](https://stripe.com/docs/payments/klarna) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub klarna: Option, + + /// Konbini allows customers in Japan to pay for bills and online purchases at convenience stores with cash. + /// + /// Check this [page](https://stripe.com/docs/payments/konbini) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub konbini: Option, + + /// [Link](https://stripe.com/docs/payments/link) is a payment method network. + /// + /// With Link, users save their payment details once, then reuse that information to pay with one click for any business on the network. + #[serde(skip_serializing_if = "Option::is_none")] + pub link: Option, + + /// Configuration name. + #[serde(skip_serializing_if = "Option::is_none")] + pub name: Option<&'a str>, + + /// OXXO is a Mexican chain of convenience stores with thousands of locations across Latin America and represents nearly 20% of online transactions in Mexico. + /// + /// OXXO allows customers to pay bills and online purchases in-store with cash. + /// Check this [page](https://stripe.com/docs/payments/oxxo) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub oxxo: Option, + + /// Przelewy24 is a Poland-based payment method aggregator that allows customers to complete transactions online using bank transfers and other methods. + /// + /// Bank transfers account for 30% of online payments in Poland and Przelewy24 provides a way for customers to pay with over 165 banks. + /// Check this [page](https://stripe.com/docs/payments/p24) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub p24: Option, + + /// PayNow is a Singapore-based payment method that allows customers to make a payment using their preferred app from participating banks and participating non-bank financial institutions. + /// + /// Check this [page](https://stripe.com/docs/payments/paynow) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub paynow: Option, + + /// PayPal, a digital wallet popular with customers in Europe, allows your customers worldwide to pay using their PayPal account. + /// + /// Check this [page](https://stripe.com/docs/payments/paypal) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub paypal: Option, + + /// PromptPay is a Thailand-based payment method that allows customers to make a payment using their preferred app from participating banks. + /// + /// Check this [page](https://stripe.com/docs/payments/promptpay) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub promptpay: Option, + + /// The [Single Euro Payments Area (SEPA)](https://en.wikipedia.org/wiki/Single_Euro_Payments_Area) is an initiative of the European Union to simplify payments within and across member countries. + /// + /// SEPA established and enforced banking standards to allow for the direct debiting of every EUR-denominated bank account within the SEPA region, check this [page](https://stripe.com/docs/payments/sepa-debit) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub sepa_debit: Option, + + /// Stripe users in Europe and the United States can use the [Payment Intents API](https://stripe.com/docs/payments/payment-intents)—a single integration path for creating payments using any supported method—to accept [Sofort](https://www.sofort.com/) payments from customers. + /// + /// Check this [page](https://stripe.com/docs/payments/sofort) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub sofort: Option, + + /// Stripe users in the United States can accept ACH direct debit payments from customers with a US bank account using the Automated Clearing House (ACH) payments system operated by Nacha. + /// + /// Check this [page](https://stripe.com/docs/payments/ach-debit) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub us_bank_account: Option, + + /// WeChat, owned by Tencent, is China's leading mobile app with over 1 billion monthly active users. + /// + /// Chinese consumers can use WeChat Pay to pay for goods and services inside of businesses' apps and websites. + /// WeChat Pay users buy most frequently in gaming, e-commerce, travel, online education, and food/nutrition. + /// Check this [page](https://stripe.com/docs/payments/wechat-pay) for more details. + #[serde(skip_serializing_if = "Option::is_none")] + pub wechat_pay: Option, +} + +impl<'a> UpdatePaymentMethodConfiguration<'a> { + pub fn new() -> Self { + UpdatePaymentMethodConfiguration { + acss_debit: Default::default(), + active: Default::default(), + affirm: Default::default(), + afterpay_clearpay: Default::default(), + alipay: Default::default(), + apple_pay: Default::default(), + apple_pay_later: Default::default(), + au_becs_debit: Default::default(), + bacs_debit: Default::default(), + bancontact: Default::default(), + blik: Default::default(), + boleto: Default::default(), + card: Default::default(), + cartes_bancaires: Default::default(), + cashapp: Default::default(), + eps: Default::default(), + expand: Default::default(), + fpx: Default::default(), + giropay: Default::default(), + google_pay: Default::default(), + grabpay: Default::default(), + ideal: Default::default(), + jcb: Default::default(), + klarna: Default::default(), + konbini: Default::default(), + link: Default::default(), + name: Default::default(), + oxxo: Default::default(), + p24: Default::default(), + paynow: Default::default(), + paypal: Default::default(), + promptpay: Default::default(), + sepa_debit: Default::default(), + sofort: Default::default(), + us_bank_account: Default::default(), + wechat_pay: Default::default(), + } + } +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationAcssDebit { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationAffirm { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationAfterpayClearpay { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationAlipay { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationApplePay { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationApplePayLater { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationAuBecsDebit { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationBacsDebit { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationBancontact { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationBlik { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationBoleto { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationCartesBancaires { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationCashapp { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationEps { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationFpx { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationGiropay { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationGooglePay { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationGrabpay { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationIdeal { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationJcb { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationKlarna { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationKonbini { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationLink { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationOxxo { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationP24 { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationPaynow { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationPaypal { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationPromptpay { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationSepaDebit { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationSofort { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationUsBankAccount { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationWechatPay { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationAcssDebit { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationAffirm { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationAfterpayClearpay { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationAlipay { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationApplePay { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationApplePayLater { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationAuBecsDebit { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationBacsDebit { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationBancontact { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationBlik { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationBoleto { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationCartesBancaires { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationCashapp { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationEps { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationFpx { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationGiropay { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationGooglePay { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationGrabpay { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationIdeal { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationJcb { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationKlarna { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationKonbini { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationLink { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationOxxo { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationP24 { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationPaynow { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationPaypal { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationPromptpay { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationSepaDebit { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationSofort { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationUsBankAccount { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationWechatPay { + + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationAcssDebitDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationAffirmDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationAfterpayClearpayDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationAlipayDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationApplePayDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationApplePayLaterDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationAuBecsDebitDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationBacsDebitDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationBancontactDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationBlikDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationBoletoDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationCartesBancairesDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationCashappDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationEpsDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationFpxDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationGiropayDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationGooglePayDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationGrabpayDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationIdealDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationJcbDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationKlarnaDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationKonbiniDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationLinkDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationOxxoDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationP24DisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationPaynowDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationPaypalDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationPromptpayDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationSepaDebitDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationSofortDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationUsBankAccountDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct CreatePaymentMethodConfigurationWechatPayDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationAcssDebitDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationAffirmDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationAfterpayClearpayDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationAlipayDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationApplePayDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationApplePayLaterDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationAuBecsDebitDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationBacsDebitDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationBancontactDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationBlikDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationBoletoDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationCartesBancairesDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationCashappDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationEpsDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationFpxDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationGiropayDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationGooglePayDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationGrabpayDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationIdealDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationJcbDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationKlarnaDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationKonbiniDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationLinkDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationOxxoDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationP24DisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationPaynowDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationPaypalDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationPromptpayDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationSepaDebitDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationSofortDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationUsBankAccountDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct UpdatePaymentMethodConfigurationWechatPayDisplayPreference { + + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationAcssDebitDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationAcssDebitDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationAcssDebitDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationAcssDebitDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationAcssDebitDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationAcssDebitDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationAcssDebitDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationAcssDebitDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationAcssDebitDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationAffirmDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationAffirmDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationAffirmDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationAffirmDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationAffirmDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationAffirmDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationAffirmDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationAffirmDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationAffirmDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationAfterpayClearpayDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationAfterpayClearpayDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationAfterpayClearpayDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationAfterpayClearpayDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationAfterpayClearpayDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationAfterpayClearpayDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationAfterpayClearpayDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationAfterpayClearpayDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationAfterpayClearpayDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationAlipayDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationAlipayDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationAlipayDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationAlipayDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationAlipayDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationAlipayDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationAlipayDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationAlipayDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationAlipayDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationApplePayDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationApplePayDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationApplePayDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationApplePayDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationApplePayDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationApplePayDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationApplePayDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationApplePayDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationApplePayDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationApplePayLaterDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationApplePayLaterDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationApplePayLaterDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationApplePayLaterDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationApplePayLaterDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationApplePayLaterDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationApplePayLaterDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationApplePayLaterDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationApplePayLaterDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationAuBecsDebitDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationAuBecsDebitDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationAuBecsDebitDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationAuBecsDebitDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationAuBecsDebitDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationAuBecsDebitDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationAuBecsDebitDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationAuBecsDebitDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationAuBecsDebitDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationBacsDebitDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationBacsDebitDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationBacsDebitDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationBacsDebitDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationBacsDebitDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationBacsDebitDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationBacsDebitDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationBacsDebitDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationBacsDebitDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationBancontactDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationBancontactDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationBancontactDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationBancontactDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationBancontactDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationBancontactDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationBancontactDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationBancontactDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationBancontactDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationBlikDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationBlikDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationBlikDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationBlikDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationBlikDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationBlikDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationBlikDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationBlikDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationBlikDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationBoletoDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationBoletoDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationBoletoDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationBoletoDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationBoletoDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationBoletoDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationBoletoDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationBoletoDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationBoletoDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationCartesBancairesDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationCartesBancairesDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationCartesBancairesDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationCartesBancairesDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationCartesBancairesDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationCartesBancairesDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationCartesBancairesDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationCartesBancairesDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationCartesBancairesDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationCashappDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationCashappDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationCashappDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationCashappDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationCashappDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationCashappDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationCashappDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationCashappDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationCashappDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationEpsDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationEpsDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationEpsDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationEpsDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationEpsDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationEpsDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationEpsDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationEpsDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationEpsDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationFpxDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationFpxDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationFpxDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationFpxDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationFpxDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationFpxDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationFpxDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationFpxDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationFpxDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationGiropayDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationGiropayDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationGiropayDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationGiropayDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationGiropayDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationGiropayDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationGiropayDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationGiropayDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationGiropayDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationGooglePayDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationGooglePayDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationGooglePayDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationGooglePayDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationGooglePayDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationGooglePayDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationGooglePayDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationGooglePayDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationGooglePayDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationGrabpayDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationGrabpayDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationGrabpayDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationGrabpayDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationGrabpayDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationGrabpayDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationGrabpayDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationGrabpayDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationGrabpayDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationIdealDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationIdealDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationIdealDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationIdealDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationIdealDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationIdealDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationIdealDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationIdealDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationIdealDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationJcbDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationJcbDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationJcbDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationJcbDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationJcbDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationJcbDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationJcbDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationJcbDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationJcbDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationKlarnaDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationKlarnaDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationKlarnaDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationKlarnaDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationKlarnaDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationKlarnaDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationKlarnaDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationKlarnaDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationKlarnaDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationKonbiniDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationKonbiniDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationKonbiniDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationKonbiniDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationKonbiniDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationKonbiniDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationKonbiniDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationKonbiniDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationKonbiniDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationLinkDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationLinkDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationLinkDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationLinkDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationLinkDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationLinkDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationLinkDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationLinkDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationLinkDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationOxxoDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationOxxoDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationOxxoDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationOxxoDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationOxxoDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationOxxoDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationOxxoDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationOxxoDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationOxxoDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationP24DisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationP24DisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationP24DisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationP24DisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationP24DisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationP24DisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationP24DisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationP24DisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationP24DisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationPaynowDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationPaynowDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationPaynowDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationPaynowDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationPaynowDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationPaynowDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationPaynowDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationPaynowDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationPaynowDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationPaypalDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationPaypalDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationPaypalDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationPaypalDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationPaypalDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationPaypalDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationPaypalDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationPaypalDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationPaypalDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationPromptpayDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationPromptpayDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationPromptpayDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationPromptpayDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationPromptpayDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationPromptpayDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationPromptpayDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationPromptpayDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationPromptpayDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationSepaDebitDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationSepaDebitDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationSepaDebitDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationSepaDebitDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationSepaDebitDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationSepaDebitDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationSepaDebitDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationSepaDebitDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationSepaDebitDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationSofortDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationSofortDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationSofortDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationSofortDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationSofortDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationSofortDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationSofortDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationSofortDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationSofortDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationUsBankAccountDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationUsBankAccountDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationUsBankAccountDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationUsBankAccountDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationUsBankAccountDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationUsBankAccountDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationUsBankAccountDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationUsBankAccountDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationUsBankAccountDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `CreatePaymentMethodConfigurationWechatPayDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum CreatePaymentMethodConfigurationWechatPayDisplayPreferencePreference { + None, + Off, + On, +} + +impl CreatePaymentMethodConfigurationWechatPayDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + CreatePaymentMethodConfigurationWechatPayDisplayPreferencePreference::None => "none", + CreatePaymentMethodConfigurationWechatPayDisplayPreferencePreference::Off => "off", + CreatePaymentMethodConfigurationWechatPayDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for CreatePaymentMethodConfigurationWechatPayDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for CreatePaymentMethodConfigurationWechatPayDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for CreatePaymentMethodConfigurationWechatPayDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `PaymentMethodConfigResourceDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum PaymentMethodConfigResourceDisplayPreferencePreference { + None, + Off, + On, +} + +impl PaymentMethodConfigResourceDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + PaymentMethodConfigResourceDisplayPreferencePreference::None => "none", + PaymentMethodConfigResourceDisplayPreferencePreference::Off => "off", + PaymentMethodConfigResourceDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for PaymentMethodConfigResourceDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for PaymentMethodConfigResourceDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for PaymentMethodConfigResourceDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `PaymentMethodConfigResourceDisplayPreference`'s `value` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum PaymentMethodConfigResourceDisplayPreferenceValue { + Off, + On, +} + +impl PaymentMethodConfigResourceDisplayPreferenceValue { + pub fn as_str(self) -> &'static str { + match self { + PaymentMethodConfigResourceDisplayPreferenceValue::Off => "off", + PaymentMethodConfigResourceDisplayPreferenceValue::On => "on", + } + } +} + +impl AsRef for PaymentMethodConfigResourceDisplayPreferenceValue { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for PaymentMethodConfigResourceDisplayPreferenceValue { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for PaymentMethodConfigResourceDisplayPreferenceValue { + fn default() -> Self { + Self::Off + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationAcssDebitDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationAcssDebitDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationAcssDebitDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationAcssDebitDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationAcssDebitDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationAcssDebitDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationAcssDebitDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationAcssDebitDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationAcssDebitDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationAffirmDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationAffirmDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationAffirmDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationAffirmDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationAffirmDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationAffirmDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationAffirmDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationAffirmDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationAffirmDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationAfterpayClearpayDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationAfterpayClearpayDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationAfterpayClearpayDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationAfterpayClearpayDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationAfterpayClearpayDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationAfterpayClearpayDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationAfterpayClearpayDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationAfterpayClearpayDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationAfterpayClearpayDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationAlipayDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationAlipayDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationAlipayDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationAlipayDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationAlipayDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationAlipayDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationAlipayDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationAlipayDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationAlipayDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationApplePayDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationApplePayDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationApplePayDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationApplePayDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationApplePayDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationApplePayDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationApplePayDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationApplePayDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationApplePayDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationApplePayLaterDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationApplePayLaterDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationApplePayLaterDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationApplePayLaterDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationApplePayLaterDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationApplePayLaterDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationApplePayLaterDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationApplePayLaterDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationApplePayLaterDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationAuBecsDebitDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationAuBecsDebitDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationAuBecsDebitDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationAuBecsDebitDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationAuBecsDebitDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationAuBecsDebitDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationAuBecsDebitDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationAuBecsDebitDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationAuBecsDebitDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationBacsDebitDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationBacsDebitDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationBacsDebitDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationBacsDebitDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationBacsDebitDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationBacsDebitDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationBacsDebitDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationBacsDebitDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationBacsDebitDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationBancontactDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationBancontactDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationBancontactDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationBancontactDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationBancontactDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationBancontactDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationBancontactDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationBancontactDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationBancontactDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationBlikDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationBlikDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationBlikDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationBlikDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationBlikDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationBlikDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationBlikDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationBlikDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationBlikDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationBoletoDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationBoletoDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationBoletoDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationBoletoDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationBoletoDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationBoletoDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationBoletoDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationBoletoDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationBoletoDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationCartesBancairesDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationCartesBancairesDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationCartesBancairesDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationCartesBancairesDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationCartesBancairesDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationCartesBancairesDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationCartesBancairesDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationCartesBancairesDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationCartesBancairesDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationCashappDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationCashappDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationCashappDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationCashappDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationCashappDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationCashappDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationCashappDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationCashappDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationCashappDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationEpsDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationEpsDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationEpsDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationEpsDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationEpsDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationEpsDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationEpsDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationEpsDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationEpsDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationFpxDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationFpxDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationFpxDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationFpxDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationFpxDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationFpxDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationFpxDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationFpxDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationFpxDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationGiropayDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationGiropayDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationGiropayDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationGiropayDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationGiropayDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationGiropayDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationGiropayDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationGiropayDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationGiropayDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationGooglePayDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationGooglePayDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationGooglePayDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationGooglePayDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationGooglePayDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationGooglePayDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationGooglePayDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationGooglePayDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationGooglePayDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationGrabpayDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationGrabpayDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationGrabpayDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationGrabpayDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationGrabpayDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationGrabpayDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationGrabpayDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationGrabpayDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationGrabpayDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationIdealDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationIdealDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationIdealDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationIdealDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationIdealDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationIdealDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationIdealDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationIdealDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationIdealDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationJcbDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationJcbDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationJcbDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationJcbDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationJcbDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationJcbDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationJcbDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationJcbDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationJcbDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationKlarnaDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationKlarnaDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationKlarnaDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationKlarnaDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationKlarnaDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationKlarnaDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationKlarnaDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationKlarnaDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationKlarnaDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationKonbiniDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationKonbiniDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationKonbiniDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationKonbiniDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationKonbiniDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationKonbiniDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationKonbiniDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationKonbiniDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationKonbiniDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationLinkDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationLinkDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationLinkDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationLinkDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationLinkDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationLinkDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationLinkDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationLinkDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationLinkDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationOxxoDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationOxxoDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationOxxoDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationOxxoDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationOxxoDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationOxxoDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationOxxoDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationOxxoDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationOxxoDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationP24DisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationP24DisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationP24DisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationP24DisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationP24DisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationP24DisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationP24DisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationP24DisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationP24DisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationPaynowDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationPaynowDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationPaynowDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationPaynowDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationPaynowDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationPaynowDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationPaynowDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationPaynowDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationPaynowDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationPaypalDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationPaypalDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationPaypalDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationPaypalDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationPaypalDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationPaypalDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationPaypalDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationPaypalDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationPaypalDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationPromptpayDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationPromptpayDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationPromptpayDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationPromptpayDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationPromptpayDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationPromptpayDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationPromptpayDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationPromptpayDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationPromptpayDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationSepaDebitDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationSepaDebitDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationSepaDebitDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationSepaDebitDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationSepaDebitDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationSepaDebitDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationSepaDebitDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationSepaDebitDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationSepaDebitDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationSofortDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationSofortDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationSofortDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationSofortDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationSofortDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationSofortDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationSofortDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationSofortDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationSofortDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationUsBankAccountDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationUsBankAccountDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationUsBankAccountDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationUsBankAccountDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationUsBankAccountDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationUsBankAccountDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationUsBankAccountDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationUsBankAccountDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationUsBankAccountDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// An enum representing the possible values of an `UpdatePaymentMethodConfigurationWechatPayDisplayPreference`'s `preference` field. +#[derive(Copy, Clone, Debug, Deserialize, Serialize, Eq, PartialEq)] +#[serde(rename_all = "snake_case")] +pub enum UpdatePaymentMethodConfigurationWechatPayDisplayPreferencePreference { + None, + Off, + On, +} + +impl UpdatePaymentMethodConfigurationWechatPayDisplayPreferencePreference { + pub fn as_str(self) -> &'static str { + match self { + UpdatePaymentMethodConfigurationWechatPayDisplayPreferencePreference::None => "none", + UpdatePaymentMethodConfigurationWechatPayDisplayPreferencePreference::Off => "off", + UpdatePaymentMethodConfigurationWechatPayDisplayPreferencePreference::On => "on", + } + } +} + +impl AsRef for UpdatePaymentMethodConfigurationWechatPayDisplayPreferencePreference { + fn as_ref(&self) -> &str { + self.as_str() + } +} + +impl std::fmt::Display for UpdatePaymentMethodConfigurationWechatPayDisplayPreferencePreference { + fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { + self.as_str().fmt(f) + } +} +impl std::default::Default for UpdatePaymentMethodConfigurationWechatPayDisplayPreferencePreference { + fn default() -> Self { + Self::None + } +} + +/// Cards are a popular way for consumers and businesses to pay online or in person. +/// +/// Stripe supports global and local card networks. +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct PaymentMethodParam { + /// Whether or not the payment method should be displayed. + #[serde(skip_serializing_if = "Option::is_none")] + pub display_preference: Option, +} + +/// Whether or not the payment method should be displayed. +#[derive(Clone, Debug, Default, Deserialize, Serialize)] +pub struct DisplayPreference { + /// The account's preference for whether or not to display this payment method. + #[serde(skip_serializing_if = "Option::is_none")] + pub preference: Option, +} diff --git a/src/resources/generated/payment_method_domain.rs b/src/resources/generated/payment_method_domain.rs index 5e036da0c..714568537 100644 --- a/src/resources/generated/payment_method_domain.rs +++ b/src/resources/generated/payment_method_domain.rs @@ -8,6 +8,8 @@ use crate::params::{Expand, List, Object, Paginable, Timestamp}; use serde::{Deserialize, Serialize}; /// The resource representing a Stripe "PaymentMethodDomainResourcePaymentMethodDomain". +/// +/// For more details see #[derive(Clone, Debug, Default, Deserialize, Serialize)] pub struct PaymentMethodDomain { /// Unique identifier for the object. diff --git a/src/resources/generated/setup_intent.rs b/src/resources/generated/setup_intent.rs index 304453740..eb62e230e 100644 --- a/src/resources/generated/setup_intent.rs +++ b/src/resources/generated/setup_intent.rs @@ -5,12 +5,12 @@ use serde::{Deserialize, Serialize}; use crate::client::{Client, Response}; -use crate::ids::{CustomerId, PaymentMethodId, SetupIntentId}; +use crate::ids::{CustomerId, PaymentMethodConfigurationId, PaymentMethodId, SetupIntentId}; use crate::params::{Expand, Expandable, List, Metadata, Object, Paginable, RangeQuery, Timestamp}; use crate::resources::{ Account, ApiErrors, Application, Currency, Customer, LinkedAccountOptionsUsBankAccount, Mandate, PaymentIntentNextActionCashappHandleRedirectOrDisplayQrCode, PaymentMethod, - SetupAttempt, + PaymentMethodConfigBizPaymentMethodConfigurationDetails, SetupAttempt, }; /// The resource representing a Stripe "SetupIntent". @@ -96,6 +96,11 @@ pub struct SetupIntent { /// ID of the payment method used with this SetupIntent. pub payment_method: Option>, + /// Information about the payment method configuration used for this Setup Intent. + #[serde(skip_serializing_if = "Option::is_none")] + pub payment_method_configuration_details: + Option, + /// Payment-method-specific configuration for this SetupIntent. pub payment_method_options: Option, @@ -456,6 +461,10 @@ pub struct CreateSetupIntent<'a> { #[serde(skip_serializing_if = "Option::is_none")] pub payment_method: Option, + /// The ID of the payment method configuration to use with this Setup Intent. + #[serde(skip_serializing_if = "Option::is_none")] + pub payment_method_configuration: Option, + /// When included, this hash creates a PaymentMethod that is set as the [`payment_method`](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-payment_method) /// value in the SetupIntent. #[serde(skip_serializing_if = "Option::is_none")] @@ -502,6 +511,7 @@ impl<'a> CreateSetupIntent<'a> { metadata: Default::default(), on_behalf_of: Default::default(), payment_method: Default::default(), + payment_method_configuration: Default::default(), payment_method_data: Default::default(), payment_method_options: Default::default(), payment_method_types: Default::default(), @@ -632,6 +642,10 @@ pub struct UpdateSetupIntent<'a> { #[serde(skip_serializing_if = "Option::is_none")] pub payment_method: Option, + /// The ID of the payment method configuration to use with this SetupIntent. + #[serde(skip_serializing_if = "Option::is_none")] + pub payment_method_configuration: Option, + /// When included, this hash creates a PaymentMethod that is set as the [`payment_method`](https://stripe.com/docs/api/setup_intents/object#setup_intent_object-payment_method) /// value in the SetupIntent. #[serde(skip_serializing_if = "Option::is_none")] @@ -659,6 +673,7 @@ impl<'a> UpdateSetupIntent<'a> { flow_directions: Default::default(), metadata: Default::default(), payment_method: Default::default(), + payment_method_configuration: Default::default(), payment_method_data: Default::default(), payment_method_options: Default::default(), payment_method_types: Default::default(), diff --git a/src/resources/generated/tax_id.rs b/src/resources/generated/tax_id.rs index 2ebb701bb..69b45dfa4 100644 --- a/src/resources/generated/tax_id.rs +++ b/src/resources/generated/tax_id.rs @@ -10,7 +10,7 @@ use crate::resources::Customer; /// The resource representing a Stripe "tax_id". /// -/// For more details see +/// For more details see #[derive(Clone, Debug, Default, Deserialize, Serialize)] pub struct TaxId { /// Unique identifier for the object.