1use serde::{Serialize, Deserialize};
2#[derive(Debug, Serialize, Deserialize, Default)]
3pub struct PaymentResponseProcessorApiSchema {
4 pub name: Option<String>,
6 pub processor_merchant_id: Option<String>,
8 pub amount_refunded: Option<i64>,
14 pub amount_captured: Option<i64>,
20}
21impl std::fmt::Display for PaymentResponseProcessorApiSchema {
22 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
23 write!(f, "{}", serde_json::to_string(self).unwrap())
24 }
25}
26#[derive(Debug, Serialize, Deserialize)]
27pub enum ThreeDSecureSkippedReasonCodeEnum {
28 #[serde(rename = "GATEWAY_UNAVAILABLE")]
29 GatewayUnavailable,
30 #[serde(rename = "DISABLED_BY_MERCHANT")]
31 DisabledByMerchant,
32 #[serde(rename = "NOT_SUPPORTED_BY_ISSUER")]
33 NotSupportedByIssuer,
34 #[serde(rename = "FAILED_TO_NEGOTIATE")]
35 FailedToNegotiate,
36 #[serde(rename = "UNKNOWN_ACS_RESPONSE")]
37 UnknownAcsResponse,
38 #[serde(rename = "3DS_SERVER_ERROR")]
39 ThreeDSecureSkippedReasonCodeEnum3DsServerError,
40 #[serde(rename = "ACQUIRER_NOT_CONFIGURED")]
41 AcquirerNotConfigured,
42 #[serde(rename = "ACQUIRER_NOT_PARTICIPATING")]
43 AcquirerNotParticipating,
44}
45#[derive(Debug, Serialize, Deserialize, Default)]
46pub struct StatusReasonApiSchema {
47 pub code: Option<String>,
49 pub type_: String,
51 pub message: Option<String>,
53 pub decline_type: Option<String>,
59}
60impl std::fmt::Display for StatusReasonApiSchema {
61 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
62 write!(f, "{}", serde_json::to_string(self).unwrap())
63 }
64}
65#[derive(Debug, Serialize, Deserialize)]
66pub struct AddressApiSchema {
67 pub country_code: CountryCodeEnum,
69 pub city: String,
71 pub last_name: Option<String>,
72 pub first_name: Option<String>,
73 pub address_line1: String,
75 pub state: Option<String>,
77 pub address_line2: Option<String>,
79 pub postal_code: Option<String>,
81}
82impl std::fmt::Display for AddressApiSchema {
83 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
84 write!(f, "{}", serde_json::to_string(self).unwrap())
85 }
86}
87#[derive(Debug, Serialize, Deserialize)]
88pub struct RefundPaymentPaymentsIdRefundPostRequired {
89 pub amount: serde_json::Value,
90 pub id: String,
91 pub reason: String,
92 pub order_id: String,
93}
94impl std::fmt::Display for RefundPaymentPaymentsIdRefundPostRequired {
95 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
96 write!(f, "{}", serde_json::to_string(self).unwrap())
97 }
98}
99#[derive(Debug, Serialize, Deserialize)]
100pub struct CardNetworkEnum(pub String);
101#[derive(Debug, Serialize, Deserialize, Default)]
102pub struct KlarnaTokenDetails {
103 pub type_: String,
104 pub brand: Option<String>,
105 pub expiry_date: Option<String>,
106 pub masked_number: Option<String>,
107}
108impl std::fmt::Display for KlarnaTokenDetails {
109 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
110 write!(f, "{}", serde_json::to_string(self).unwrap())
111 }
112}
113#[derive(Debug, Serialize, Deserialize)]
114pub struct OrderFeesApiSchema {
115 pub type_: Option<String>,
117 pub amount: serde_json::Value,
119 pub description: Option<String>,
121}
122impl std::fmt::Display for OrderFeesApiSchema {
123 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
124 write!(f, "{}", serde_json::to_string(self).unwrap())
125 }
126}
127#[derive(Debug, Serialize, Deserialize)]
128pub struct CheckoutPaymentMethodOptionsApiSchema {
129 pub vault_on_success: Option<bool>,
131 pub descriptor: Option<String>,
133 pub payment_type: Option<String>,
143 pub options: Option<serde_json::Value>,
146}
147impl std::fmt::Display for CheckoutPaymentMethodOptionsApiSchema {
148 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
149 write!(f, "{}", serde_json::to_string(self).unwrap())
150 }
151}
152#[derive(Debug, Serialize, Deserialize, Default)]
153pub struct ErrorObject {
154 pub diagnostics_id: Option<String>,
156 pub error_id: Option<String>,
158 pub description: Option<String>,
160 pub validation_errors: Option<Vec<serde_json::Value>>,
162}
163impl std::fmt::Display for ErrorObject {
164 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
165 write!(f, "{}", serde_json::to_string(self).unwrap())
166 }
167}
168#[derive(Debug, Serialize, Deserialize)]
169pub struct KlarnaSessionDetailsApiSchema {
170 pub billing_address: KlarnaAddressApiSchema,
171 pub order_lines: Vec<serde_json::Value>,
172 pub recurring_description: Option<String>,
173 pub shipping_address: Option<KlarnaAddressApiSchema>,
174 pub locale: String,
175 pub token_details: Option<KlarnaTokenDetails>,
176 pub purchase_country: String,
177 pub purchase_currency: String,
178}
179impl std::fmt::Display for KlarnaSessionDetailsApiSchema {
180 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
181 write!(f, "{}", serde_json::to_string(self).unwrap())
182 }
183}
184#[derive(Debug, Serialize, Deserialize)]
185pub struct VerifiedMerchantPaymentMethodTokenApiResponse {
186 pub is_verified: bool,
188 pub merchant_payment_method_token_api_response: MerchantPaymentMethodTokenApiResponse,
189}
190impl std::fmt::Display for VerifiedMerchantPaymentMethodTokenApiResponse {
191 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
192 write!(f, "{}", serde_json::to_string(self).unwrap())
193 }
194}
195#[derive(Debug, Serialize, Deserialize)]
196pub struct PaymentCaptureApiRequest {
197 pub final_: Option<bool>,
201 pub amount: Option<serde_json::Value>,
205}
206impl std::fmt::Display for PaymentCaptureApiRequest {
207 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
208 write!(f, "{}", serde_json::to_string(self).unwrap())
209 }
210}
211#[derive(Debug, Serialize, Deserialize)]
212pub struct CheckoutPaymentMethodOptionCardNetworkApiSchema {
213 pub card_network_type: Option<serde_json::Value>,
218}
219impl std::fmt::Display for CheckoutPaymentMethodOptionCardNetworkApiSchema {
220 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
221 write!(f, "{}", serde_json::to_string(self).unwrap())
222 }
223}
224#[derive(Debug, Serialize, Deserialize, Default)]
225pub struct PaymentCancelApiRequest {
226 pub reason: Option<String>,
228}
229impl std::fmt::Display for PaymentCancelApiRequest {
230 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
231 write!(f, "{}", serde_json::to_string(self).unwrap())
232 }
233}
234#[derive(Debug, Serialize, Deserialize)]
235pub enum BlockingPaymentActionTypeEnum {
236 #[serde(rename = "3DS_AUTHENTICATION")]
237 BlockingPaymentActionTypeEnum3DsAuthentication,
238 #[serde(rename = "USE_PRIMER_SDK")]
239 UsePrimerSdk,
240}
241#[derive(Debug, Serialize, Deserialize)]
242pub struct CreateClientSideTokenClientSessionPostRequired {
243 pub order_id: String,
244 pub metadata: serde_json::Value,
245 pub currency_code: String,
246 pub customer_id: String,
247 pub order: OrderDetailsApiSchema,
248 pub customer: CheckoutCustomerDetailsApiSchema,
249 pub payment_method: CheckoutPaymentMethodOptionsApiSchema,
250 pub amount: serde_json::Value,
251}
252impl std::fmt::Display for CreateClientSideTokenClientSessionPostRequired {
253 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
254 write!(f, "{}", serde_json::to_string(self).unwrap())
255 }
256}
257#[derive(Debug, Serialize, Deserialize, Default)]
258pub struct VerifiedMerchantPaymentMethodTokenListApiResponse {
259 pub data: Option<Vec<VerifiedMerchantPaymentMethodTokenApiResponse>>,
260}
261impl std::fmt::Display for VerifiedMerchantPaymentMethodTokenListApiResponse {
262 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
263 write!(f, "{}", serde_json::to_string(self).unwrap())
264 }
265}
266#[derive(Debug, Serialize, Deserialize)]
267pub enum RecurringTransactionTypeEnum {
268 #[serde(rename = "FIRST_PAYMENT")]
269 FirstPayment,
270 #[serde(rename = "ECOMMERCE")]
271 Ecommerce,
272 #[serde(rename = "SUBSCRIPTION")]
273 Subscription,
274 #[serde(rename = "UNSCHEDULED")]
275 Unscheduled,
276}
277#[derive(Debug, Serialize, Deserialize)]
278pub struct CoreApiApiCommonsSchemasAddessAddressApiSchema {
279 pub address_line1: Option<String>,
280 pub postal_code: Option<String>,
281 pub address_line2: Option<String>,
282 pub last_name: Option<String>,
283 pub state: Option<String>,
284 pub first_name: Option<String>,
285 pub city: Option<String>,
286 pub country_code: Option<CountryCodeEnum>,
288}
289impl std::fmt::Display for CoreApiApiCommonsSchemasAddessAddressApiSchema {
290 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
291 write!(f, "{}", serde_json::to_string(self).unwrap())
292 }
293}
294#[derive(Debug, Serialize, Deserialize)]
295pub struct KlarnaAddressApiSchema {
296 pub address_line2: Option<String>,
297 pub email: Option<String>,
298 pub city: Option<String>,
299 pub first_name: Option<String>,
300 pub postal_code: Option<String>,
301 pub title: Option<String>,
302 pub last_name: Option<String>,
303 pub phone_number: Option<String>,
304 pub address_line1: Option<String>,
305 pub address_line3: Option<String>,
306 pub country_code: Option<CountryCodeEnum>,
308 pub state: Option<String>,
309}
310impl std::fmt::Display for KlarnaAddressApiSchema {
311 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
312 write!(f, "{}", serde_json::to_string(self).unwrap())
313 }
314}
315#[derive(Debug, Serialize, Deserialize)]
316pub struct PaymentCardTokenApiSchema {
317 pub cardholder_name: Option<String>,
318 pub is_network_tokenized: Option<bool>,
319 pub expiration_month: String,
320 pub network: Option<String>,
321 pub expiration_year: String,
322 pub first6_digits: Option<String>,
323 pub last4_digits: String,
324 pub bin_data: Option<BinDataApiSchema>,
325}
326impl std::fmt::Display for PaymentCardTokenApiSchema {
327 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
328 write!(f, "{}", serde_json::to_string(self).unwrap())
329 }
330}
331#[derive(Debug, Serialize, Deserialize)]
332pub enum PrepaidReloadableEnum {
333 #[serde(rename = "RELOADABLE")]
334 Reloadable,
335 #[serde(rename = "NON_RELOADABLE")]
336 NonReloadable,
337 #[serde(rename = "NOT_APPLICABLE")]
338 NotApplicable,
339 #[serde(rename = "UNKNOWN")]
340 Unknown,
341}
342#[derive(Debug, Serialize, Deserialize)]
343pub struct ThreeDSecureAuthenticationApiSchema {
344 pub protocol_version: Option<String>,
345 pub response_code: String,
347 pub challenge_issued: Option<bool>,
348 pub reason_text: Option<String>,
349 pub reason_code: Option<serde_json::Value>,
350}
351impl std::fmt::Display for ThreeDSecureAuthenticationApiSchema {
352 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
353 write!(f, "{}", serde_json::to_string(self).unwrap())
354 }
355}
356#[derive(Debug, Serialize, Deserialize)]
357pub struct OrderShippingApiSchema {
358 pub amount: Option<serde_json::Value>,
360}
361impl std::fmt::Display for OrderShippingApiSchema {
362 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
363 write!(f, "{}", serde_json::to_string(self).unwrap())
364 }
365}
366#[derive(Debug, Serialize, Deserialize)]
367pub struct PaymentApiResponse {
368 pub payment_method: Option<PaymentResponsePaymentMethodOptionsApiSchema>,
370 pub order_id: Option<String>,
372 pub customer_id: Option<String>,
374 pub customer: Option<CustomerDetailsApiSchema>,
376 pub processor: Option<PaymentResponseProcessorApiSchema>,
378 pub transactions: Option<Vec<TransactionOverviewApiSchema>>,
382 pub date: Option<String>,
384 pub metadata: Option<serde_json::Value>,
387 pub order: Option<OrderDetailsApiSchema>,
389 pub id: Option<String>,
395 pub status_reason: Option<StatusReasonApiSchema>,
398 pub status: Option<String>,
400 pub currency_code: Option<String>,
404 pub amount: Option<serde_json::Value>,
406 pub required_action: Option<PaymentRequiredActionApiSchema>,
408}
409impl std::fmt::Display for PaymentApiResponse {
410 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
411 write!(f, "{}", serde_json::to_string(self).unwrap())
412 }
413}
414#[derive(Debug, Serialize, Deserialize)]
415pub struct KlarnaCustomerTokenApiSchema {
416 pub klarna_customer_token: String,
417 pub session_data: KlarnaSessionDetailsApiSchema,
418}
419impl std::fmt::Display for KlarnaCustomerTokenApiSchema {
420 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
421 write!(f, "{}", serde_json::to_string(self).unwrap())
422 }
423}
424#[derive(Debug, Serialize, Deserialize, Default)]
425pub struct BinDataOptionalApiSchema {
426 pub network: Option<String>,
429}
430impl std::fmt::Display for BinDataOptionalApiSchema {
431 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
432 write!(f, "{}", serde_json::to_string(self).unwrap())
433 }
434}
435#[derive(Debug, Serialize, Deserialize)]
436pub enum DeclineTypeEnum {
437 #[serde(rename = "SOFT_DECLINE")]
438 SoftDecline,
439 #[serde(rename = "HARD_DECLINE")]
440 HardDecline,
441}
442#[derive(Debug, Serialize, Deserialize)]
443pub struct PaymentRefundApiRequest {
444 pub amount: Option<serde_json::Value>,
448 pub reason: Option<String>,
450 pub order_id: Option<String>,
454}
455impl std::fmt::Display for PaymentRefundApiRequest {
456 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
457 write!(f, "{}", serde_json::to_string(self).unwrap())
458 }
459}
460#[derive(Debug, Serialize, Deserialize)]
461pub enum ProductTypeEnum {
462 #[serde(rename = "PHYSICAL")]
463 Physical,
464 #[serde(rename = "DIGITAL")]
465 Digital,
466}
467#[derive(Debug, Serialize, Deserialize, Default)]
468pub struct PaymentRequiredActionApiSchema {
469 pub name: String,
471 pub description: String,
473 pub client_token: Option<String>,
475}
476impl std::fmt::Display for PaymentRequiredActionApiSchema {
477 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
478 write!(f, "{}", serde_json::to_string(self).unwrap())
479 }
480}
481#[derive(Debug, Serialize, Deserialize, Default)]
482pub struct MerchantPaymentMethodTokenListApiResponse {
483 pub data: Option<Vec<MerchantPaymentMethodTokenApiResponse>>,
484}
485impl std::fmt::Display for MerchantPaymentMethodTokenListApiResponse {
486 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
487 write!(f, "{}", serde_json::to_string(self).unwrap())
488 }
489}
490#[derive(Debug, Serialize, Deserialize)]
491pub struct Currency(pub serde_json::Value);
492#[derive(Debug, Serialize, Deserialize, Default)]
493pub struct ClientSessionWarningsApiResponse {
494 pub code: Option<String>,
496 pub message: Option<String>,
498 pub type_: Option<String>,
500}
501impl std::fmt::Display for ClientSessionWarningsApiResponse {
502 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
503 write!(f, "{}", serde_json::to_string(self).unwrap())
504 }
505}
506#[derive(Debug, Serialize, Deserialize)]
507pub struct PaymentSummaryApiSchema {
508 pub order_id: String,
510 pub amount: i64,
512 pub id: String,
518 pub processor: Option<String>,
520 pub status: String,
522 pub metadata: Option<serde_json::Value>,
530 pub date: String,
532 pub currency_code: String,
536}
537impl std::fmt::Display for PaymentSummaryApiSchema {
538 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
539 write!(f, "{}", serde_json::to_string(self).unwrap())
540 }
541}
542#[derive(Debug, Serialize, Deserialize)]
543pub struct Error422Response {
544 pub error_object: ErrorObject,
545}
546impl std::fmt::Display for Error422Response {
547 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
548 write!(f, "{}", serde_json::to_string(self).unwrap())
549 }
550}
551#[derive(Debug, Serialize, Deserialize)]
552pub struct PayPalOrderTokenApiSchema {
553 pub external_payer_info: Option<PayPalExternalPayerInfoApiSchema>,
555 pub paypal_status: Option<String>,
556 pub paypal_order_id: String,
557}
558impl std::fmt::Display for PayPalOrderTokenApiSchema {
559 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
560 write!(f, "{}", serde_json::to_string(self).unwrap())
561 }
562}
563#[derive(Debug, Serialize, Deserialize)]
564pub struct ClientSessionApiRequest {
565 pub customer_id: Option<String>,
568 pub order_id: Option<String>,
570 pub amount: Option<serde_json::Value>,
576 pub customer: Option<CheckoutCustomerDetailsApiSchema>,
578 pub order: Option<OrderDetailsApiSchema>,
580 pub payment_method: Option<CheckoutPaymentMethodOptionsApiSchema>,
582 pub currency_code: Option<String>,
586 pub metadata: Option<serde_json::Value>,
594}
595impl std::fmt::Display for ClientSessionApiRequest {
596 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
597 write!(f, "{}", serde_json::to_string(self).unwrap())
598 }
599}
600#[derive(Debug, Serialize, Deserialize)]
601pub struct Error400Response {
602 pub error_object: ErrorObject,
603}
604impl std::fmt::Display for Error400Response {
605 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
606 write!(f, "{}", serde_json::to_string(self).unwrap())
607 }
608}
609#[derive(Debug, Serialize, Deserialize, Default)]
610pub struct PaymentResumeApiRequest {
611 pub resume_token: String,
613}
614impl std::fmt::Display for PaymentResumeApiRequest {
615 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
616 write!(f, "{}", serde_json::to_string(self).unwrap())
617 }
618}
619#[derive(Debug, Serialize, Deserialize, Default)]
620pub struct PaymentRequestPaymentMethodOptionsApiSchema {
621 pub descriptor: Option<String>,
623 pub vault_on_success: Option<bool>,
625 pub payment_type: Option<String>,
635}
636impl std::fmt::Display for PaymentRequestPaymentMethodOptionsApiSchema {
637 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
638 write!(f, "{}", serde_json::to_string(self).unwrap())
639 }
640}
641#[derive(Debug, Serialize, Deserialize)]
642pub struct CheckoutPaymentMethodOptionApiSchema {
643 pub surcharge: Option<CheckoutPaymentMethodOptionSurchargeApiSchema>,
645}
646impl std::fmt::Display for CheckoutPaymentMethodOptionApiSchema {
647 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
648 write!(f, "{}", serde_json::to_string(self).unwrap())
649 }
650}
651#[derive(Debug, Serialize, Deserialize)]
652pub struct TransactionOverviewApiSchema {
653 pub processor_transaction_id: Option<String>,
655 pub date: String,
657 pub processor_status: Option<String>,
659 pub processor_merchant_id: String,
666 pub amount: serde_json::Value,
668 pub currency_code: String,
673 pub processor_name: Option<String>,
675 pub processor_status_reason: Option<StatusReasonApiSchema>,
680 pub transaction_type: Option<String>,
681}
682impl std::fmt::Display for TransactionOverviewApiSchema {
683 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
684 write!(f, "{}", serde_json::to_string(self).unwrap())
685 }
686}
687#[derive(Debug, Serialize, Deserialize)]
688pub enum AccountFundingTypeEnum {
689 #[serde(rename = "CREDIT")]
690 Credit,
691 #[serde(rename = "DEBIT")]
692 Debit,
693 #[serde(rename = "PREPAID")]
694 Prepaid,
695 #[serde(rename = "CHARGE")]
696 Charge,
697 #[serde(rename = "DEFERRED_DEBIT")]
698 DeferredDebit,
699 #[serde(rename = "UNKNOWN")]
700 Unknown,
701}
702#[derive(Debug, Serialize, Deserialize)]
703pub struct ClientSessionUpdateApiRequest {
704 pub order: Option<OrderDetailsApiSchema>,
709 pub order_id: Option<String>,
711 pub customer: Option<CheckoutCustomerDetailsApiSchema>,
716 pub payment_method: Option<CheckoutPaymentMethodOptionsApiSchema>,
718 pub currency_code: Option<String>,
723 pub amount: Option<serde_json::Value>,
729 pub metadata: Option<serde_json::Value>,
734 pub customer_id: Option<String>,
736 pub client_token: Option<String>,
738}
739impl std::fmt::Display for ClientSessionUpdateApiRequest {
740 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
741 write!(f, "{}", serde_json::to_string(self).unwrap())
742 }
743}
744#[derive(Debug, Serialize, Deserialize)]
745pub struct ClientSessionApiResponse {
746 pub customer: Option<CustomerDetailsApiSchema>,
748 pub customer_id: Option<String>,
750 pub order: Option<OrderDetailsApiSchema>,
752 pub order_id: Option<String>,
754 pub metadata: Option<serde_json::Value>,
757 pub amount: Option<serde_json::Value>,
760 pub payment_method: Option<CheckoutPaymentMethodOptionsApiSchema>,
762 pub currency_code: Option<String>,
766}
767impl std::fmt::Display for ClientSessionApiResponse {
768 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
769 write!(f, "{}", serde_json::to_string(self).unwrap())
770 }
771}
772#[derive(Debug, Serialize, Deserialize, Default)]
773pub struct PaymentListApiResponse {
774 pub next_cursor: Option<String>,
775 pub data: Option<Vec<PaymentSummaryApiSchema>>,
776 pub prev_cursor: Option<String>,
777}
778impl std::fmt::Display for PaymentListApiResponse {
779 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
780 write!(f, "{}", serde_json::to_string(self).unwrap())
781 }
782}
783#[derive(Debug, Serialize, Deserialize)]
784pub struct PaymentResponsePaymentMethodOptionsApiSchema {
785 pub payment_method_token: Option<String>,
787 pub payment_method_type: Option<String>,
789 pub is_vaulted: Option<bool>,
791 pub descriptor: Option<String>,
793 pub analytics_id: Option<String>,
795 pub payment_method_data: Option<serde_json::Value>,
797 pub three_d_secure_authentication: Option<ThreeDSecureAuthenticationApiSchema>,
798}
799impl std::fmt::Display for PaymentResponsePaymentMethodOptionsApiSchema {
800 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
801 write!(f, "{}", serde_json::to_string(self).unwrap())
802 }
803}
804#[derive(Debug, Serialize, Deserialize)]
805pub struct CountryCodeEnum(pub serde_json::Value);
806#[derive(Debug, Serialize, Deserialize)]
807pub enum ThreeDSecureFailedReasonCodeEnum {
808 #[serde(rename = "UNKNOWN")]
809 Unknown,
810 #[serde(rename = "REJECTED_BY_ISSUER")]
811 RejectedByIssuer,
812 #[serde(rename = "CARD_AUTHENTICATION_FAILED")]
813 CardAuthenticationFailed,
814 #[serde(rename = "UNKNOWN_DEVICE")]
815 UnknownDevice,
816 #[serde(rename = "UNSUPPORTED_DEVICE")]
817 UnsupportedDevice,
818 #[serde(rename = "EXCEEDS_AUTHENTICATION_FREQUENCY_LIMIT")]
819 ExceedsAuthenticationFrequencyLimit,
820 #[serde(rename = "EXPIRED_CARD")]
821 ExpiredCard,
822 #[serde(rename = "INVALID_CARD_NUMBER")]
823 InvalidCardNumber,
824 #[serde(rename = "INVALID_TRANSACTION")]
825 InvalidTransaction,
826 #[serde(rename = "NO_CARD_RECORD")]
827 NoCardRecord,
828 #[serde(rename = "SECURITY_FAILURE")]
829 SecurityFailure,
830 #[serde(rename = "STOLEN_CARD")]
831 StolenCard,
832 #[serde(rename = "SUSPECTED_FRAUD")]
833 SuspectedFraud,
834 #[serde(rename = "TRANSACTION_NOT_PERMITTED_TO_CARDHOLDER")]
835 TransactionNotPermittedToCardholder,
836 #[serde(rename = "CARDHOLDER_NOT_ENROLLED_IN_SERVICE")]
837 CardholderNotEnrolledInService,
838 #[serde(rename = "TRANSACTION_TIMED_OUT_AT_THE_ACS")]
839 TransactionTimedOutAtTheAcs,
840 #[serde(rename = "LOW_CONFIDENCE")]
841 LowConfidence,
842 #[serde(rename = "MEDIUM_CONFIDENCE")]
843 MediumConfidence,
844 #[serde(rename = "HIGH_CONFIDENCE")]
845 HighConfidence,
846 #[serde(rename = "VERY_HIGH_CONFIDENCE")]
847 VeryHighConfidence,
848 #[serde(rename = "EXCEEDS_ACS_MAXIMUM_CHALLENGES")]
849 ExceedsAcsMaximumChallenges,
850 #[serde(rename = "NON_PAYMENT_NOT_SUPPORTED")]
851 NonPaymentNotSupported,
852 #[serde(rename = "THREE_RI_NOT_SUPPORTED")]
853 ThreeRiNotSupported,
854 #[serde(rename = "ACS_TECHNICAL_ISSUE")]
855 AcsTechnicalIssue,
856 #[serde(rename = "DECOUPLED_REQUIRED_BY_ACS")]
857 DecoupledRequiredByAcs,
858 #[serde(rename = "DECOUPLED_MAX_EXPIRY_EXCEEDED")]
859 DecoupledMaxExpiryExceeded,
860 #[serde(rename = "DECOUPLED_AUTHENTICATION_INSUFFICIENT_TIME")]
861 DecoupledAuthenticationInsufficientTime,
862 #[serde(rename = "AUTHENTICATION_ATTEMPTED_BUT_NOT_PERFORMED_BY_CARDHOLDER")]
863 AuthenticationAttemptedButNotPerformedByCardholder,
864 #[serde(rename = "ACS_TIMED_OUT")]
865 AcsTimedOut,
866 #[serde(rename = "INVALID_ACS_RESPONSE")]
867 InvalidAcsResponse,
868 #[serde(rename = "ACS_SYSTEM_ERROR_RESPONSE")]
869 AcsSystemErrorResponse,
870 #[serde(rename = "ERROR_GENERATING_CAVV")]
871 ErrorGeneratingCavv,
872 #[serde(rename = "PROTOCOL_VERSION_NOT_SUPPORTED")]
873 ProtocolVersionNotSupported,
874 #[serde(rename = "TRANSACTION_EXCLUDED_FROM_ATTEMPTS_PROCESSING")]
875 TransactionExcludedFromAttemptsProcessing,
876 #[serde(rename = "REQUESTED_PROGRAM_NOT_SUPPORTED")]
877 RequestedProgramNotSupported,
878}
879#[derive(Debug, Serialize, Deserialize)]
880pub struct CheckoutCustomerDetailsApiSchema {
881 pub last_name: Option<String>,
883 pub email_address: Option<String>,
886 pub shipping_address: Option<CoreApiApiCommonsSchemasAddessAddressApiSchema>,
888 pub billing_address: Option<CoreApiApiCommonsSchemasAddessAddressApiSchema>,
891 pub tax_id: Option<String>,
893 pub first_name: Option<String>,
895 pub mobile_number: Option<String>,
897 pub national_document_id: Option<String>,
899}
900impl std::fmt::Display for CheckoutCustomerDetailsApiSchema {
901 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
902 write!(f, "{}", serde_json::to_string(self).unwrap())
903 }
904}
905#[derive(Debug, Serialize, Deserialize)]
906pub struct MerchantPaymentMethodTokenApiResponse {
907 pub created_at: Option<String>,
909 pub deleted_at: Option<String>,
911 pub customer_id: Option<String>,
913 pub deleted: Option<bool>,
915 pub payment_method_type: Option<String>,
917 pub analytics_id: Option<String>,
919 pub payment_method_data: Option<serde_json::Value>,
921 pub default: Option<bool>,
923 pub description: Option<String>,
925 pub token: Option<String>,
927 pub token_type: Option<String>,
929}
930impl std::fmt::Display for MerchantPaymentMethodTokenApiResponse {
931 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
932 write!(f, "{}", serde_json::to_string(self).unwrap())
933 }
934}
935#[derive(Debug, Serialize, Deserialize)]
936pub enum TransactionDeclineReasonV2Enum {
937 #[serde(rename = "ERROR")]
938 Error,
939 #[serde(rename = "INVALID_CARD_NUMBER")]
940 InvalidCardNumber,
941 #[serde(rename = "EXPIRED_CARD")]
942 ExpiredCard,
943 #[serde(rename = "LOST_OR_STOLEN_CARD")]
944 LostOrStolenCard,
945 #[serde(rename = "SUSPECTED_FRAUD")]
946 SuspectedFraud,
947 #[serde(rename = "UNKNOWN")]
948 Unknown,
949 #[serde(rename = "DECLINED")]
950 Declined,
951 #[serde(rename = "REFER_TO_CARD_ISSUER")]
952 ReferToCardIssuer,
953 #[serde(rename = "DO_NOT_HONOR")]
954 DoNotHonor,
955 #[serde(rename = "INSUFFICIENT_FUNDS")]
956 InsufficientFunds,
957 #[serde(rename = "WITHDRAWAL_LIMIT_EXCEEDED")]
958 WithdrawalLimitExceeded,
959 #[serde(rename = "ISSUER_TEMPORARILY_UNAVAILABLE")]
960 IssuerTemporarilyUnavailable,
961 #[serde(rename = "AUTHENTICATION_REQUIRED")]
962 AuthenticationRequired,
963}
964#[derive(Debug, Serialize, Deserialize, Default)]
965pub struct CheckoutPaymentMethodOptionSurchargeApiSchema {
966 pub amount: Option<i64>,
968}
969impl std::fmt::Display for CheckoutPaymentMethodOptionSurchargeApiSchema {
970 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
971 write!(f, "{}", serde_json::to_string(self).unwrap())
972 }
973}
974#[derive(Debug, Serialize, Deserialize, Default)]
975pub struct VaultPaymentMethodApiRequest {
976 pub customer_id: String,
978 pub verify: Option<bool>,
980}
981impl std::fmt::Display for VaultPaymentMethodApiRequest {
982 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
983 write!(f, "{}", serde_json::to_string(self).unwrap())
984 }
985}
986#[derive(Debug, Serialize, Deserialize)]
987pub enum CardRegionRestrictionEnum {
988 #[serde(rename = "DOMESTIC_USE_ONLY")]
989 DomesticUseOnly,
990 #[serde(rename = "NONE")]
991 None,
992 #[serde(rename = "UNKNOWN")]
993 Unknown,
994}
995#[derive(Debug, Serialize, Deserialize, Default)]
996pub struct OrderLineItemsProductDataApiSchema {
997 pub brand: Option<String>,
999 pub sku: Option<String>,
1001 pub color: Option<String>,
1003 pub global_trade_item_number: Option<String>,
1005 pub weight_unit: Option<String>,
1007 pub manufacturer_part_number: Option<String>,
1009 pub weight: Option<f64>,
1011}
1012impl std::fmt::Display for OrderLineItemsProductDataApiSchema {
1013 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
1014 write!(f, "{}", serde_json::to_string(self).unwrap())
1015 }
1016}
1017#[derive(Debug, Serialize, Deserialize)]
1018pub struct ClientSessionWithTokenApiResponse {
1019 pub amount: Option<serde_json::Value>,
1025 pub order_id: Option<String>,
1027 pub client_token_expiration_date: Option<String>,
1029 pub client_token: Option<String>,
1031 pub order: Option<OrderDetailsApiSchema>,
1033 pub customer_id: Option<String>,
1035 pub customer: Option<CustomerDetailsApiSchema>,
1037 pub payment_method: Option<CheckoutPaymentMethodOptionsApiSchema>,
1039 pub currency_code: Option<String>,
1042 pub warnings: Option<ClientSessionWarningsApiResponse>,
1044 pub metadata: Option<serde_json::Value>,
1047}
1048impl std::fmt::Display for ClientSessionWithTokenApiResponse {
1049 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
1050 write!(f, "{}", serde_json::to_string(self).unwrap())
1051 }
1052}
1053#[derive(Debug, Serialize, Deserialize, Default)]
1054pub struct IdealPayNlTokenApiSchema {
1055 pub payment_method_config_id: String,
1056}
1057impl std::fmt::Display for IdealPayNlTokenApiSchema {
1058 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
1059 write!(f, "{}", serde_json::to_string(self).unwrap())
1060 }
1061}
1062#[derive(Debug, Serialize, Deserialize, Default)]
1063pub struct ApayaCustomerTokenApiSchema {
1064 pub mnc: Option<i64>,
1065 pub mx: String,
1066 pub mcc: Option<i64>,
1067}
1068impl std::fmt::Display for ApayaCustomerTokenApiSchema {
1069 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
1070 write!(f, "{}", serde_json::to_string(self).unwrap())
1071 }
1072}
1073#[derive(Debug, Serialize, Deserialize)]
1074pub struct PaymentCreationApiRequest {
1075 pub order_id: Option<String>,
1077 pub metadata: Option<serde_json::Value>,
1085 pub payment_method: Option<PaymentRequestPaymentMethodOptionsApiSchema>,
1087 pub amount: Option<serde_json::Value>,
1091 pub customer_id: Option<String>,
1094 pub currency_code: Option<String>,
1098 pub payment_method_token: String,
1101 pub customer: Option<CustomerDetailsApiSchema>,
1104 pub order: Option<OrderDetailsApiSchema>,
1106}
1107impl std::fmt::Display for PaymentCreationApiRequest {
1108 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
1109 write!(f, "{}", serde_json::to_string(self).unwrap())
1110 }
1111}
1112#[derive(Debug, Serialize, Deserialize)]
1113pub struct OrderDetailsApiSchema {
1114 pub fees: Option<Vec<OrderFeesApiSchema>>,
1116 pub country_code: Option<CountryCodeEnum>,
1118 pub shipping: Option<OrderShippingApiSchema>,
1120 pub line_items: Option<Vec<OrderLineItemsApiSchema>>,
1122}
1123impl std::fmt::Display for OrderDetailsApiSchema {
1124 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
1125 write!(f, "{}", serde_json::to_string(self).unwrap())
1126 }
1127}
1128#[derive(Debug, Serialize, Deserialize)]
1129pub struct PaymentMethodTypeEnum(pub String);
1130#[derive(Debug, Serialize, Deserialize)]
1131pub struct CheckoutPaymentMethodCardOptionApiSchema {
1132 pub networks: Option<CheckoutPaymentMethodOptionCardNetworkApiSchema>,
1133}
1134impl std::fmt::Display for CheckoutPaymentMethodCardOptionApiSchema {
1135 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
1136 write!(f, "{}", serde_json::to_string(self).unwrap())
1137 }
1138}
1139#[derive(Debug, Serialize, Deserialize)]
1140pub enum ThreeDSecureAuthResponseCodeEnum {
1141 #[serde(rename = "NOT_PERFORMED")]
1142 NotPerformed,
1143 #[serde(rename = "SKIPPED")]
1144 Skipped,
1145 #[serde(rename = "AUTH_SUCCESS")]
1146 AuthSuccess,
1147 #[serde(rename = "AUTH_FAILED")]
1148 AuthFailed,
1149 #[serde(rename = "CHALLENGE")]
1150 Challenge,
1151 #[serde(rename = "METHOD")]
1152 Method,
1153}
1154#[derive(Debug, Serialize, Deserialize)]
1155pub enum TransactionTypeEnum {
1156 #[serde(rename = "SALE")]
1157 Sale,
1158 #[serde(rename = "REFUND")]
1159 Refund,
1160}
1161#[derive(Debug, Serialize, Deserialize)]
1162pub struct CustomerDetailsApiSchema {
1163 pub email_address: Option<String>,
1168 pub first_name: Option<String>,
1170 pub last_name: Option<String>,
1172 pub billing_address: Option<CoreApiApiCommonsSchemasAddessAddressApiSchema>,
1177 pub mobile_number: Option<String>,
1179 pub shipping_address: Option<CoreApiApiCommonsSchemasAddessAddressApiSchema>,
1181 pub tax_id: Option<String>,
1183 pub national_document_id: Option<String>,
1185}
1186impl std::fmt::Display for CustomerDetailsApiSchema {
1187 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
1188 write!(f, "{}", serde_json::to_string(self).unwrap())
1189 }
1190}
1191#[derive(Debug, Serialize, Deserialize)]
1192pub struct BinDataApiSchema {
1193 pub issuer_currency_code: Option<Currency>,
1195 pub network: String,
1198 pub product_usage_type: String,
1200 pub product_code: String,
1201 pub issuer_country_code: Option<CountryCodeEnum>,
1203 pub regional_restriction: String,
1205 pub account_number_type: String,
1207 pub account_funding_type: String,
1209 pub issuer_name: Option<String>,
1210 pub prepaid_reloadable_indicator: String,
1212 pub product_name: String,
1213}
1214impl std::fmt::Display for BinDataApiSchema {
1215 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
1216 write!(f, "{}", serde_json::to_string(self).unwrap())
1217 }
1218}
1219#[derive(Debug, Serialize, Deserialize, Default)]
1220pub struct PaymentSummaryProcessorApiSchema {
1221 pub processor_merchant_id: Option<String>,
1223 pub name: String,
1225}
1226impl std::fmt::Display for PaymentSummaryProcessorApiSchema {
1227 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
1228 write!(f, "{}", serde_json::to_string(self).unwrap())
1229 }
1230}
1231#[derive(Debug, Serialize, Deserialize, Default)]
1232pub struct GoCardlessMandateApiSchema {
1233 pub gocardless_mandate_id: String,
1235}
1236impl std::fmt::Display for GoCardlessMandateApiSchema {
1237 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
1238 write!(f, "{}", serde_json::to_string(self).unwrap())
1239 }
1240}
1241#[derive(Debug, Serialize, Deserialize, Default)]
1242pub struct PayPalExternalPayerInfoApiSchema {
1243 pub last_name: Option<String>,
1244 pub external_payer_id: Option<String>,
1245 pub first_name: Option<String>,
1246 pub email: Option<String>,
1247}
1248impl std::fmt::Display for PayPalExternalPayerInfoApiSchema {
1249 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
1250 write!(f, "{}", serde_json::to_string(self).unwrap())
1251 }
1252}
1253#[derive(Debug, Serialize, Deserialize)]
1254pub enum CardAccountNumberTypeEnum {
1255 #[serde(rename = "PRIMARY_ACCOUNT_NUMBER")]
1256 PrimaryAccountNumber,
1257 #[serde(rename = "NETWORK_TOKEN")]
1258 NetworkToken,
1259 #[serde(rename = "UNKNOWN")]
1260 Unknown,
1261}
1262#[derive(Debug, Serialize, Deserialize)]
1263pub struct KlarnaPaymentSessionApiSchema {
1264 pub session_data: KlarnaSessionDetailsApiSchema,
1265 pub klarna_authorization_token: String,
1266}
1267impl std::fmt::Display for KlarnaPaymentSessionApiSchema {
1268 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
1269 write!(f, "{}", serde_json::to_string(self).unwrap())
1270 }
1271}
1272#[derive(Debug, Serialize, Deserialize)]
1273pub enum TokenTypeEnum {
1274 #[serde(rename = "MULTI_USE")]
1275 MultiUse,
1276 #[serde(rename = "SINGLE_USE")]
1277 SingleUse,
1278}
1279#[derive(Debug, Serialize, Deserialize)]
1280pub enum PaymentStatus {
1281 #[serde(rename = "PENDING")]
1282 Pending,
1283 #[serde(rename = "FAILED")]
1284 Failed,
1285 #[serde(rename = "AUTHORIZED")]
1286 Authorized,
1287 #[serde(rename = "SETTLING")]
1288 Settling,
1289 #[serde(rename = "PARTIALLY_SETTLED")]
1290 PartiallySettled,
1291 #[serde(rename = "SETTLED")]
1292 Settled,
1293 #[serde(rename = "DECLINED")]
1294 Declined,
1295 #[serde(rename = "CANCELLED")]
1296 Cancelled,
1297}
1298#[derive(Debug, Serialize, Deserialize)]
1299pub struct OrderLineItemsApiSchema {
1300 pub item_id: Option<String>,
1302 pub quantity: Option<i64>,
1304 pub tax_code: Option<String>,
1306 pub name: Option<String>,
1308 pub amount: serde_json::Value,
1310 pub product_data: Option<OrderLineItemsProductDataApiSchema>,
1312 pub product_type: Option<String>,
1314 pub discount_amount: Option<serde_json::Value>,
1316 pub tax_amount: Option<i64>,
1318 pub description: Option<String>,
1320}
1321impl std::fmt::Display for OrderLineItemsApiSchema {
1322 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
1323 write!(f, "{}", serde_json::to_string(self).unwrap())
1324 }
1325}
1326#[derive(Debug, Serialize, Deserialize)]
1327pub struct PayPalBillingAgreementApiSchema {
1328 pub shipping_address: Option<AddressApiSchema>,
1330 pub external_payer_info: Option<PayPalExternalPayerInfoApiSchema>,
1332 pub paypal_billing_agreement_id: String,
1333 pub paypal_status: Option<String>,
1334}
1335impl std::fmt::Display for PayPalBillingAgreementApiSchema {
1336 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
1337 write!(f, "{}", serde_json::to_string(self).unwrap())
1338 }
1339}
1340#[derive(Debug, Serialize, Deserialize, Default)]
1341pub struct PaymentCardTokenApiSchemaPaymentMethodsApi {
1342 pub account_funding_type: Option<String>,
1344 pub last4_digits: String,
1345 pub cardholder_name: Option<String>,
1346 pub expiration_year: String,
1347 pub expiration_month: String,
1348 pub network_transaction_id: Option<String>,
1350 pub network: Option<String>,
1351}
1352impl std::fmt::Display for PaymentCardTokenApiSchemaPaymentMethodsApi {
1353 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
1354 write!(f, "{}", serde_json::to_string(self).unwrap())
1355 }
1356}
1357#[derive(Debug, Serialize, Deserialize)]
1358pub enum PaymentStatusTypeEnum {
1359 #[serde(rename = "APPLICATION_ERROR")]
1360 ApplicationError,
1361 #[serde(rename = "GATEWAY_REJECTED")]
1362 GatewayRejected,
1363 #[serde(rename = "ISSUER_DECLINED")]
1364 IssuerDeclined,
1365}
1366#[derive(Debug, Serialize, Deserialize)]
1367pub struct UpdateClientSideTokenClientSessionPatchRequired {
1368 pub currency_code: String,
1369 pub customer: CheckoutCustomerDetailsApiSchema,
1370 pub amount: serde_json::Value,
1371 pub metadata: serde_json::Value,
1372 pub order: OrderDetailsApiSchema,
1373 pub order_id: String,
1374 pub customer_id: String,
1375 pub client_token: String,
1376 pub payment_method: CheckoutPaymentMethodOptionsApiSchema,
1377}
1378impl std::fmt::Display for UpdateClientSideTokenClientSessionPatchRequired {
1379 fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> Result<(), std::fmt::Error> {
1380 write!(f, "{}", serde_json::to_string(self).unwrap())
1381 }
1382}
1383#[derive(Debug, Serialize, Deserialize)]
1384pub enum CardProductTypeEnum {
1385 #[serde(rename = "CONSUMER")]
1386 Consumer,
1387 #[serde(rename = "BUSINESS")]
1388 Business,
1389 #[serde(rename = "GOVERNMENT")]
1390 Government,
1391 #[serde(rename = "UNKNOWN")]
1392 Unknown,
1393}