Open source, composable payments platform | PCI compliant | SaaS and Self-host options | Enables connectivity to multiple payment, payout, fraud, vault and tokenization providers | Uplifts authorization with intelligent routing and revenue recovery | Reduce payment processing costs with cost observability | Reduces payment ops with reconciliation
Rust adyenbeginner-friendlyfeaturedfinancefintechhacktoberfesthigh-performanceopen-sourceorchestrationpaymentpayment-gatewaypayment-integrationpayment-processingpaymentspayments-platformrestful-apirustsdkstripeworks-with-react
refactor(core): populate surcharge_details in payment list api (#12956)
Swangi Kumari3086caecc9c6
diff --git a/crates/router/src/core/payments/transformers.rs b/crates/router/src/core/payments/transformers.rsindex f311189274..c87eb4ae9f 100644--- a/crates/router/src/core/payments/transformers.rs+++ b/crates/router/src/core/payments/transformers.rs@@ -4740,7 +4740,12 @@ impl ForeignFrom<(storage::PaymentIntent, storage::PaymentAttempt)> for api::Payfeature_metadata: None,reference_id: None,payment_link: None,- surcharge_details: None,+ surcharge_details: pa.net_amount.get_surcharge_amount().map(|surcharge_amount| {+ RequestSurchargeDetails {+ surcharge_amount,+ tax_amount: pa.net_amount.get_tax_on_surcharge(),+ }+ }),merchant_decision: None,incremental_authorization_allowed: None,authorization_count: None,