Bug: Add support for Samsung Pay payment method



This is to support for Samsung pay as a payment method.
This also needs to add a new field in merchant connector account create `connector_wallet_details` which is required to collect the required credentials for Samsung Pay. As this column in the data base stores the data in the encrypted format we also want to migrate apple pay certificates from metadata to `connector_wallet_details`, for which we are inserting apple pay details passed in the metadata to connector_wallet_details. 

Once the frontend changes are done to pass the apple pay credentials in the connector_wallet_details this fallback can be removed.
diff --git a/api-reference-v2/openapi_spec.json b/api-reference-v2/openapi_spec.json
index 5465d902388..a250a8a9c37 100644
--- a/api-reference-v2/openapi_spec.json
+++ b/api-reference-v2/openapi_spec.json
@@ -5521,6 +5521,27 @@
           }
         }
       },
+      "ConnectorWalletDetails": {
+        "type": "object",
+        "properties": {
+          "apple_pay_combined": {
+            "type": "object",
+            "description": "This field contains the Apple Pay certificates and credentials for iOS and Web Apple Pay flow",
+            "nullable": true
+          },
+          "apple_pay": {
+            "type": "object",
+            "description": "This field is for our legacy Apple Pay flow that contains the Apple Pay certificates and credentials for only iOS Apple Pay flow",
+            "nullable": true
+          },
+          "samsung_pay": {
+            "type": "object",
+            "description": "This field contains the Samsung Pay certificates and credentials",
+            "nullable": true
+          }
+        },
+        "additionalProperties": false
+      },
       "CountryAlpha2": {
         "type": "string",
         "enum": [
@@ -9254,6 +9275,14 @@
               }
             ],
             "nullable": true
+          },
+          "connector_wallets_details": {
+            "allOf": [
+              {
+                "$ref": "#/components/schemas/ConnectorWalletDetails"
+              }
+            ],
+            "nullable": true
           }
         },
         "additionalProperties": false
@@ -9450,6 +9479,14 @@
               }
             ],
             "nullable": true
+          },
+          "connector_wallets_details": {
+            "allOf": [
+              {
+                "$ref": "#/components/schemas/ConnectorWalletDetails"
+              }
+            ],
+            "nullable": true
           }
         },
         "additionalProperties": false
@@ -9591,6 +9628,14 @@
               }
             ],
             "nullable": true
+          },
+          "connector_wallets_details": {
+            "allOf": [
+              {
+                "$ref": "#/components/schemas/ConnectorWalletDetails"
+              }
+            ],
+            "nullable": true
           }
         },
         "additionalProperties": false
@@ -9716,6 +9761,14 @@
               }
             ],
             "nullable": true
+          },
+          "connector_wallets_details": {
+            "allOf": [
+              {
+                "$ref": "#/components/schemas/ConnectorWalletDetails"
+              }
+            ],
+            "nullable": true
           }
         },
         "additionalProperties": false
@@ -17929,15 +17982,164 @@
           }
         }
       },
-      "SamsungPayWalletData": {
+      "SamsungPayAmountDetails": {
         "type": "object",
         "required": [
-          "token"
+          "option",
+          "currency_code",
+          "total"
         ],
         "properties": {
-          "token": {
+          "option": {
+            "$ref": "#/components/schemas/SamsungPayAmountFormat"
+          },
+          "currency_code": {
+            "$ref": "#/components/schemas/Currency"
+          },
+          "total": {
+            "type": "string",
+            "description": "The total amount of the transaction",
+            "example": "38.02"
+          }
+        }
+      },
+      "SamsungPayAmountFormat": {
+        "type": "string",
+        "enum": [
+          "FORMAT_TOTAL_PRICE_ONLY",
+          "FORMAT_TOTAL_ESTIMATED_AMOUNT"
+        ]
+      },
+      "SamsungPayMerchantPaymentInformation": {
+        "type": "object",
+        "required": [
+          "name",
+          "url",
+          "country_code"
+        ],
+        "properties": {
+          "name": {
+            "type": "string",
+            "description": "Merchant name, this will be displayed on the Samsung Pay screen"
+          },
+          "url": {
+            "type": "string",
+            "description": "Merchant domain that process payments"
+          },
+          "country_code": {
+            "$ref": "#/components/schemas/CountryAlpha2"
+          }
+        }
+      },
+      "SamsungPayProtocolType": {
+        "type": "string",
+        "enum": [
+          "PROTOCOL3DS"
+        ]
+      },
+      "SamsungPaySessionTokenResponse": {
+        "type": "object",
+        "required": [
+          "version",
+          "service_id",
+          "order_number",
+          "merchant",
+          "amount",
+          "protocol",
+          "allowed_brands"
+        ],
+        "properties": {
+          "version": {
+            "type": "string",
+            "description": "Samsung Pay API version"
+          },
+          "service_id": {
+            "type": "string",
+            "description": "Samsung Pay service ID to which session call needs to be made"
+          },
+          "order_number": {
+            "type": "string",
+            "description": "Order number of the transaction"
+          },
+          "merchant": {
+            "$ref": "#/components/schemas/SamsungPayMerchantPaymentInformation"
+          },
+          "amount": {
+            "$ref": "#/components/schemas/SamsungPayAmountDetails"
+          },
+          "protocol": {
+            "$ref": "#/components/schemas/SamsungPayProtocolType"
+          },
+          "allowed_brands": {
+            "type": "array",
+            "items": {
+              "type": "string"
+            },
+            "description": "List of supported card brands"
+          }
+        }
+      },
+      "SamsungPayTokenData": {
+        "type": "object",
+        "required": [
+          "version",
+          "data"
+        ],
+        "properties": {
+          "type": {
+            "type": "string",
+            "description": "3DS type used by Samsung Pay",
+            "nullable": true
+          },
+          "version": {
             "type": "string",
-            "description": "The encrypted payment token from Samsung"
+            "description": "3DS version used by Samsung Pay"
+          },
+          "data": {
+            "type": "string",
+            "description": "Samsung Pay encrypted payment credential data"
+          }
+        }
+      },
+      "SamsungPayWalletCredentials": {
+        "type": "object",
+        "required": [
+          "card_brand",
+          "card_last4digits",
+          "3_d_s"
+        ],
+        "properties": {
+          "method": {
+            "type": "string",
+            "description": "Specifies authentication method used",
+            "nullable": true
+          },
+          "recurring_payment": {
+            "type": "boolean",
+            "description": "Value if credential is enabled for recurring payment",
+            "nullable": true
+          },
+          "card_brand": {
+            "type": "string",
+            "description": "Brand of the payment card"
+          },
+          "card_last4digits": {
+            "type": "string",
+            "description": "Last 4 digits of the card number"
+          },
+          "3_d_s": {
+            "$ref": "#/components/schemas/SamsungPayTokenData"
+          }
+        }
+      },
+      "SamsungPayWalletData": {
+        "type": "object",
+        "required": [
+          "payment_credential"
+        ],
+        "properties": {
+          "payment_credential": {
+            "$ref": "#/components/schemas/SamsungPayWalletCredentials"
           }
         }
       },
@@ -18145,6 +18347,27 @@
               }
             ]
           },
+          {
+            "allOf": [
+              {
+                "$ref": "#/components/schemas/SamsungPaySessionTokenResponse"
+              },
+              {
+                "type": "object",
+                "required": [
+                  "wallet_name"
+                ],
+                "properties": {
+                  "wallet_name": {
+                    "type": "string",
+                    "enum": [
+                      "samsung_pay"
+                    ]
+                  }
+                }
+              }
+            ]
+          },
           {
             "allOf": [
               {
diff --git a/config/config.example.toml b/config/config.example.toml
index a6af984b01f..861785dc34c 100644
--- a/config/config.example.toml
+++ b/config/config.example.toml
@@ -534,6 +534,7 @@ credit = { currency = "USD,GBP,EUR" }
 debit = { currency = "USD,GBP,EUR" }
 apple_pay = { currency = "USD,GBP,EUR" }
 google_pay = { currency = "USD,GBP,EUR" }
+samsung_pay = { currency = "USD,GBP,EUR" }
 
 [pm_filters.stax]
 credit = { currency = "USD" }
diff --git a/config/deployments/integration_test.toml b/config/deployments/integration_test.toml
index abb50a2c2f0..3a54c5ef08f 100644
--- a/config/deployments/integration_test.toml
+++ b/config/deployments/integration_test.toml
@@ -304,6 +304,7 @@ credit = { currency = "USD,GBP,EUR" }
 debit = { currency = "USD,GBP,EUR" }
 apple_pay = { currency = "USD,GBP,EUR" }
 google_pay = { currency = "USD,GBP,EUR" }
+samsung_pay = { currency = "USD,GBP,EUR" }
 
 [pm_filters.volt]
 open_banking_uk = {country = "DE,GB,AT,BE,CY,EE,ES,FI,FR,GR,HR,IE,IT,LT,LU,LV,MT,NL,PT,SI,SK,BG,CZ,DK,HU,NO,PL,RO,SE,AU,BR", currency = "EUR,GBP,DKK,NOK,PLN,SEK,AUD,BRL"}
diff --git a/config/deployments/production.toml b/config/deployments/production.toml
index 38799c23858..ec3737a5c64 100644
--- a/config/deployments/production.toml
+++ b/config/deployments/production.toml
@@ -278,6 +278,7 @@ credit = { currency = "USD,GBP,EUR" }
 debit = { currency = "USD,GBP,EUR" }
 apple_pay = { currency = "USD,GBP,EUR" }
 google_pay = { currency = "USD,GBP,EUR" }
+samsung_pay = { currency = "USD,GBP,EUR" }
 
 [pm_filters.braintree]
 paypal.currency = "AUD,BRL,CAD,CNY,CZK,DKK,EUR,HKD,HUF,ILS,JPY,MYR,MXN,TWD,NZD,NOK,PHP,PLN,GBP,RUB,SGD,SEK,CHF,THB,USD"
diff --git a/config/deployments/sandbox.toml b/config/deployments/sandbox.toml
index 2217a72429c..1c605ef35ac 100644
--- a/config/deployments/sandbox.toml
+++ b/config/deployments/sandbox.toml
@@ -281,6 +281,7 @@ credit = { currency = "USD,GBP,EUR" }
 debit = { currency = "USD,GBP,EUR" }
 apple_pay = { currency = "USD,GBP,EUR" }
 google_pay = { currency = "USD,GBP,EUR" }
+samsung_pay = { currency = "USD,GBP,EUR" }
 
 [pm_filters.braintree]
 paypal.currency = "AUD,BRL,CAD,CNY,CZK,DKK,EUR,HKD,HUF,ILS,JPY,MYR,MXN,TWD,NZD,NOK,PHP,PLN,GBP,RUB,SGD,SEK,CHF,THB,USD"
diff --git a/config/development.toml b/config/development.toml
index 43130cb78f2..6e56d5bb14d 100644
--- a/config/development.toml
+++ b/config/development.toml
@@ -449,6 +449,7 @@ credit = { currency = "USD,GBP,EUR" }
 debit = { currency = "USD,GBP,EUR" }
 apple_pay = { currency = "USD,GBP,EUR" }
 google_pay = { currency = "USD,GBP,EUR" }
+samsung_pay = { currency = "USD,GBP,EUR" }
 
 [pm_filters.braintree]
 paypal = { currency = "AUD,BRL,CAD,CNY,CZK,DKK,EUR,HKD,HUF,ILS,JPY,MYR,MXN,TWD,NZD,NOK,PHP,PLN,GBP,RUB,SGD,SEK,CHF,THB,USD" }
diff --git a/config/docker_compose.toml b/config/docker_compose.toml
index 2c6b12a88a0..15038da0125 100644
--- a/config/docker_compose.toml
+++ b/config/docker_compose.toml
@@ -414,6 +414,7 @@ credit = { currency = "USD,GBP,EUR" }
 debit = { currency = "USD,GBP,EUR" }
 apple_pay = { currency = "USD,GBP,EUR" }
 google_pay = { currency = "USD,GBP,EUR" }
+samsung_pay = { currency = "USD,GBP,EUR" }
 
 [pm_filters.helcim]
 credit = { currency = "USD" }
diff --git a/crates/api_models/src/admin.rs b/crates/api_models/src/admin.rs
index 3b9a8e1c983..cbbb17525b6 100644
--- a/crates/api_models/src/admin.rs
+++ b/crates/api_models/src/admin.rs
@@ -736,6 +736,10 @@ pub struct MerchantConnectorCreate {
     /// In case the merchant needs to store any additional sensitive data
     #[schema(value_type = Option<AdditionalMerchantData>)]
     pub additional_merchant_data: Option<AdditionalMerchantData>,
+
+    /// The connector_wallets_details is used to store wallet details such as certificates and wallet credentials
+    #[schema(value_type = Option<ConnectorWalletDetails>)]
+    pub connector_wallets_details: Option<ConnectorWalletDetails>,
 }
 
 #[cfg(feature = "v2")]
@@ -873,6 +877,10 @@ pub struct MerchantConnectorCreate {
     /// In case the merchant needs to store any additional sensitive data
     #[schema(value_type = Option<AdditionalMerchantData>)]
     pub additional_merchant_data: Option<AdditionalMerchantData>,
+
+    /// The connector_wallets_details is used to store wallet details such as certificates and wallet credentials
+    #[schema(value_type = Option<ConnectorWalletDetails>)]
+    pub connector_wallets_details: Option<ConnectorWalletDetails>,
 }
 
 #[cfg(feature = "v1")]
@@ -1093,6 +1101,10 @@ pub struct MerchantConnectorResponse {
 
     #[schema(value_type = Option<AdditionalMerchantData>)]
     pub additional_merchant_data: Option<AdditionalMerchantData>,
+
+    /// The connector_wallets_details is used to store wallet details such as certificates and wallet credentials
+    #[schema(value_type = Option<ConnectorWalletDetails>)]
+    pub connector_wallets_details: Option<ConnectorWalletDetails>,
 }
 
 #[cfg(feature = "v2")]
@@ -1212,6 +1224,10 @@ pub struct MerchantConnectorResponse {
 
     #[schema(value_type = Option<AdditionalMerchantData>)]
     pub additional_merchant_data: Option<AdditionalMerchantData>,
+
+    /// The connector_wallets_details is used to store wallet details such as certificates and wallet credentials
+    #[schema(value_type = Option<ConnectorWalletDetails>)]
+    pub connector_wallets_details: Option<ConnectorWalletDetails>,
 }
 
 #[cfg(feature = "v1")]
@@ -1318,6 +1334,10 @@ pub struct MerchantConnectorListResponse {
 
     #[schema(value_type = Option<AdditionalMerchantData>)]
     pub additional_merchant_data: Option<AdditionalMerchantData>,
+
+    /// The connector_wallets_details is used to store wallet details such as certificates and wallet credentials
+    #[schema(value_type = Option<ConnectorWalletDetails>)]
+    pub connector_wallets_details: Option<ConnectorWalletDetails>,
 }
 
 #[cfg(feature = "v1")]
@@ -1408,6 +1428,10 @@ pub struct MerchantConnectorListResponse {
 
     #[schema(value_type = Option<AdditionalMerchantData>)]
     pub additional_merchant_data: Option<AdditionalMerchantData>,
+
+    /// The connector_wallets_details is used to store wallet details such as certificates and wallet credentials
+    #[schema(value_type = Option<ConnectorWalletDetails>)]
+    pub connector_wallets_details: Option<ConnectorWalletDetails>,
 }
 
 #[cfg(feature = "v2")]
@@ -1503,6 +1527,28 @@ pub struct MerchantConnectorUpdate {
     /// In case the merchant needs to store any additional sensitive data
     #[schema(value_type = Option<AdditionalMerchantData>)]
     pub additional_merchant_data: Option<AdditionalMerchantData>,
+
+    /// The connector_wallets_details is used to store wallet details such as certificates and wallet credentials
+    #[schema(value_type = Option<ConnectorWalletDetails>)]
+    pub connector_wallets_details: Option<ConnectorWalletDetails>,
+}
+
+#[derive(Debug, Clone, Serialize, Deserialize, ToSchema)]
+#[serde(deny_unknown_fields)]
+
+pub struct ConnectorWalletDetails {
+    /// This field contains the Apple Pay certificates and credentials for iOS and Web Apple Pay flow
+    #[serde(skip_serializing_if = "Option::is_none")]
+    #[schema(value_type = Option<Object>)]
+    pub apple_pay_combined: Option<pii::SecretSerdeValue>,
+    /// This field is for our legacy Apple Pay flow that contains the Apple Pay certificates and credentials for only iOS Apple Pay flow
+    #[serde(skip_serializing_if = "Option::is_none")]
+    #[schema(value_type = Option<Object>)]
+    pub apple_pay: Option<pii::SecretSerdeValue>,
+    /// This field contains the Samsung Pay certificates and credentials
+    #[serde(skip_serializing_if = "Option::is_none")]
+    #[schema(value_type = Option<Object>)]
+    pub samsung_pay: Option<pii::SecretSerdeValue>,
 }
 
 /// Create a new Merchant Connector for the merchant account. The connector could be a payment processor / facilitator / acquirer or specialized services like Fraud / Accounting etc."
@@ -1588,6 +1634,9 @@ pub struct MerchantConnectorUpdate {
     /// In case the merchant needs to store any additional sensitive data
     #[schema(value_type = Option<AdditionalMerchantData>)]
     pub additional_merchant_data: Option<AdditionalMerchantData>,
+
+    /// The connector_wallets_details is used to store wallet details such as certificates and wallet credentials
+    pub connector_wallets_details: Option<ConnectorWalletDetails>,
 }
 
 #[cfg(feature = "v2")]
diff --git a/crates/api_models/src/payments.rs b/crates/api_models/src/payments.rs
index 715bf3c3544..59cc0e0548f 100644
--- a/crates/api_models/src/payments.rs
+++ b/crates/api_models/src/payments.rs
@@ -2788,9 +2788,37 @@ impl GetAddressFromPaymentMethodData for WalletData {
 #[derive(Eq, PartialEq, Clone, Debug, serde::Deserialize, serde::Serialize, ToSchema)]
 #[serde(rename_all = "snake_case")]
 pub struct SamsungPayWalletData {
-    /// The encrypted payment token from Samsung
+    pub payment_credential: SamsungPayWalletCredentials,
+}
+
+#[derive(Eq, PartialEq, Clone, Debug, serde::Deserialize, serde::Serialize, ToSchema)]
+#[serde(rename_all = "snake_case")]
+pub struct SamsungPayWalletCredentials {
+    /// Specifies authentication method used
+    pub method: Option<String>,
+    /// Value if credential is enabled for recurring payment
+    pub recurring_payment: Option<bool>,
+    /// Brand of the payment card
+    pub card_brand: String,
+    /// Last 4 digits of the card number
+    #[serde(rename = "card_last4digits")]
+    pub card_last_four_digits: String,
+    /// Samsung Pay token data
+    #[serde(rename = "3_d_s")]
+    pub token_data: SamsungPayTokenData,
+}
+
+#[derive(Eq, PartialEq, Clone, Debug, serde::Deserialize, serde::Serialize, ToSchema)]
+#[serde(rename_all = "snake_case")]
+pub struct SamsungPayTokenData {
+    /// 3DS type used by Samsung Pay
+    #[serde(rename = "type")]
+    pub three_ds_type: Option<String>,
+    /// 3DS version used by Samsung Pay
+    pub version: String,
+    /// Samsung Pay encrypted payment credential data
     #[schema(value_type = String)]
-    pub token: Secret<String>,
+    pub data: Secret<String>,
 }
 
 #[derive(Eq, PartialEq, Clone, Debug, serde::Deserialize, serde::Serialize, ToSchema)]
@@ -4789,6 +4817,20 @@ pub struct GpaySessionTokenData {
     pub data: GpayMetaData,
 }
 
+#[derive(Debug, Clone, serde::Serialize, serde::Deserialize)]
+pub struct SamsungPaySessionTokenData {
+    #[serde(rename = "samsung_pay")]
+    pub data: SamsungPayMetadata,
+}
+
+#[derive(Debug, Clone, serde::Serialize, serde::Deserialize)]
+pub struct SamsungPayMetadata {
+    pub service_id: String,
+    pub merchant_display_name: String,
+    pub merchant_business_country: api_enums::CountryAlpha2,
+    pub allowed_brands: Vec<String>,
+}
+
 #[derive(Debug, Clone, serde::Serialize, serde::Deserialize)]
 pub struct PaypalSdkMetaData {
     pub client_id: String,
@@ -4954,6 +4996,8 @@ pub struct SessionTokenForSimplifiedApplePay {
 pub enum SessionToken {
     /// The session response structure for Google Pay
     GooglePay(Box<GpaySessionTokenResponse>),
+    /// The session response structure for Samsung Pay
+    SamsungPay(Box<SamsungPaySessionTokenResponse>),
     /// The session response structure for Klarna
     Klarna(Box<KlarnaSessionTokenResponse>),
     /// The session response structure for PayPal
@@ -5011,6 +5055,68 @@ pub struct GooglePaySessionResponse {
     pub secrets: Option<SecretInfoToInitiateSdk>,
 }
 
+#[derive(Debug, Clone, Eq, PartialEq, serde::Serialize, ToSchema)]
+#[serde(rename_all = "lowercase")]
+pub struct SamsungPaySessionTokenResponse {
+    /// Samsung Pay API version
+    pub version: String,
+    /// Samsung Pay service ID to which session call needs to be made
+    pub service_id: String,
+    /// Order number of the transaction
+    pub order_number: String,
+    /// Field containing merchant information
+    #[serde(rename = "merchant")]
+    pub merchant_payment_information: SamsungPayMerchantPaymentInformation,
+    /// Field containing the payment amount
+    pub amount: SamsungPayAmountDetails,
+    /// Payment protocol type
+    pub protocol: SamsungPayProtocolType,
+    /// List of supported card brands
+    pub allowed_brands: Vec<String>,
+}
+
+#[derive(Debug, Clone, Eq, PartialEq, serde::Serialize, ToSchema)]
+#[serde(rename_all = "SCREAMING_SNAKE_CASE")]
+pub enum SamsungPayProtocolType {
+    Protocol3ds,
+}
+
+#[derive(Debug, Clone, Eq, PartialEq, serde::Serialize, ToSchema)]
+#[serde(rename_all = "lowercase")]
+pub struct SamsungPayMerchantPaymentInformation {
+    /// Merchant name, this will be displayed on the Samsung Pay screen
+    pub name: String,
+    /// Merchant domain that process payments
+    pub url: String,
+    /// Merchant country code
+    #[schema(value_type = CountryAlpha2, example = "US")]
+    pub country_code: api_enums::CountryAlpha2,
+}
+
+#[derive(Debug, Clone, Eq, PartialEq, serde::Serialize, ToSchema)]
+#[serde(rename_all = "lowercase")]
+pub struct SamsungPayAmountDetails {
+    #[serde(rename = "option")]
+    /// Amount format to be displayed
+    pub amount_format: SamsungPayAmountFormat,
+    /// The currency code
+    #[schema(value_type = Currency, example = "USD")]
+    pub currency_code: api_enums::Currency,
+    /// The total amount of the transaction
+    #[serde(rename = "total")]
+    #[schema(value_type = String, example = "38.02")]
+    pub total_amount: StringMajorUnit,
+}
+
+#[derive(Debug, Clone, Eq, PartialEq, serde::Serialize, ToSchema)]
+#[serde(rename_all = "SCREAMING_SNAKE_CASE")]
+pub enum SamsungPayAmountFormat {
+    /// Display the total amount only
+    FormatTotalPriceOnly,
+    /// Display "Total (Estimated amount)" and total amount
+    FormatTotalEstimatedAmount,
+}
+
 #[derive(Debug, Clone, Eq, PartialEq, serde::Serialize, ToSchema)]
 #[serde(rename_all = "lowercase")]
 pub struct GpayShippingAddressParameters {
diff --git a/crates/connector_configs/src/transformer.rs b/crates/connector_configs/src/transformer.rs
index fe39da67a93..68ade2909b4 100644
--- a/crates/connector_configs/src/transformer.rs
+++ b/crates/connector_configs/src/transformer.rs
@@ -56,7 +56,7 @@ impl DashboardRequestPayload {
                 | (Connector::Stripe, WeChatPay) => {
                     Some(api_models::enums::PaymentExperience::DisplayQrCode)
                 }
-                (_, GooglePay) | (_, ApplePay) => {
+                (_, GooglePay) | (_, ApplePay) | (_, PaymentMethodType::SamsungPay) => {
                     Some(api_models::enums::PaymentExperience::InvokeSdkClient)
                 }
                 _ => Some(api_models::enums::PaymentExperience::RedirectToUrl),
diff --git a/crates/hyperswitch_domain_models/src/payment_method_data.rs b/crates/hyperswitch_domain_models/src/payment_method_data.rs
index b21bedd880c..9f505f26712 100644
--- a/crates/hyperswitch_domain_models/src/payment_method_data.rs
+++ b/crates/hyperswitch_domain_models/src/payment_method_data.rs
@@ -135,10 +135,30 @@ pub struct MifinityData {
 }
 
 #[derive(Eq, PartialEq, Clone, Debug, serde::Deserialize, serde::Serialize)]
-
+#[serde(rename_all = "snake_case")]
 pub struct SamsungPayWalletData {
-    /// The encrypted payment token from Samsung
-    pub token: Secret<String>,
+    pub payment_credential: SamsungPayWalletCredentials,
+}
+
+#[derive(Eq, PartialEq, Clone, Debug, serde::Deserialize, serde::Serialize)]
+#[serde(rename_all = "snake_case")]
+pub struct SamsungPayWalletCredentials {
+    pub method: Option<String>,
+    pub recurring_payment: Option<bool>,
+    pub card_brand: String,
+    #[serde(rename = "card_last4digits")]
+    pub card_last_four_digits: String,
+    #[serde(rename = "3_d_s")]
+    pub token_data: SamsungPayTokenData,
+}
+
+#[derive(Eq, PartialEq, Clone, Debug, serde::Deserialize, serde::Serialize)]
+#[serde(rename_all = "snake_case")]
+pub struct SamsungPayTokenData {
+    #[serde(rename = "type")]
+    pub three_ds_type: Option<String>,
+    pub version: String,
+    pub data: Secret<String>,
 }
 
 #[derive(Eq, PartialEq, Clone, Debug, serde::Deserialize, serde::Serialize)]
@@ -670,9 +690,7 @@ impl From<api_models::payments::WalletData> for WalletData {
                 })
             }
             api_models::payments::WalletData::SamsungPay(samsung_pay_data) => {
-                Self::SamsungPay(Box::new(SamsungPayWalletData {
-                    token: samsung_pay_data.token,
-                }))
+                Self::SamsungPay(Box::new(SamsungPayWalletData::from(samsung_pay_data)))
             }
             api_models::payments::WalletData::TwintRedirect {} => Self::TwintRedirect {},
             api_models::payments::WalletData::VippsRedirect {} => Self::VippsRedirect {},
@@ -736,6 +754,24 @@ impl From<api_models::payments::ApplePayWalletData> for ApplePayWalletData {
     }
 }
 
+impl From<Box<api_models::payments::SamsungPayWalletData>> for SamsungPayWalletData {
+    fn from(value: Box<api_models::payments::SamsungPayWalletData>) -> Self {
+        Self {
+            payment_credential: SamsungPayWalletCredentials {
+                method: value.payment_credential.method,
+                recurring_payment: value.payment_credential.recurring_payment,
+                card_brand: value.payment_credential.card_brand,
+                card_last_four_digits: value.payment_credential.card_last_four_digits,
+                token_data: SamsungPayTokenData {
+                    three_ds_type: value.payment_credential.token_data.three_ds_type,
+                    version: value.payment_credential.token_data.version,
+                    data: value.payment_credential.token_data.data,
+                },
+            },
+        }
+    }
+}
+
 impl From<api_models::payments::PayLaterData> for PayLaterData {
     fn from(value: api_models::payments::PayLaterData) -> Self {
         match value {
diff --git a/crates/hyperswitch_interfaces/src/errors.rs b/crates/hyperswitch_interfaces/src/errors.rs
index e36707af6b0..f9c407ff587 100644
--- a/crates/hyperswitch_interfaces/src/errors.rs
+++ b/crates/hyperswitch_interfaces/src/errors.rs
@@ -41,6 +41,8 @@ pub enum ConnectorError {
     FailedToObtainCertificate,
     #[error("Connector meta data not found")]
     NoConnectorMetaData,
+    #[error("Connector wallet details not found")]
+    NoConnectorWalletDetails,
     #[error("Failed to obtain certificate key")]
     FailedToObtainCertificateKey,
     #[error("This step has not been implemented for: {0}")]
diff --git a/crates/kgraph_utils/benches/evaluation.rs b/crates/kgraph_utils/benches/evaluation.rs
index b98b854fba8..858c013f41d 100644
--- a/crates/kgraph_utils/benches/evaluation.rs
+++ b/crates/kgraph_utils/benches/evaluation.rs
@@ -71,6 +71,7 @@ fn build_test_data(
         pm_auth_config: None,
         status: api_enums::ConnectorStatus::Inactive,
         additional_merchant_data: None,
+        connector_wallets_details: None,
     };
 
     #[cfg(feature = "v1")]
@@ -95,6 +96,7 @@ fn build_test_data(
         pm_auth_config: None,
         status: api_enums::ConnectorStatus::Inactive,
         additional_merchant_data: None,
+        connector_wallets_details: None,
     };
     let config = CountryCurrencyFilter {
         connector_configs: HashMap::new(),
diff --git a/crates/kgraph_utils/src/mca.rs b/crates/kgraph_utils/src/mca.rs
index 7d04f5d4238..2ec0cbe8031 100644
--- a/crates/kgraph_utils/src/mca.rs
+++ b/crates/kgraph_utils/src/mca.rs
@@ -759,6 +759,7 @@ mod tests {
             pm_auth_config: None,
             status: api_enums::ConnectorStatus::Inactive,
             additional_merchant_data: None,
+            connector_wallets_details: None,
         };
         #[cfg(feature = "v1")]
         let stripe_account = MerchantConnectorResponse {
@@ -818,6 +819,7 @@ mod tests {
             pm_auth_config: None,
             status: api_enums::ConnectorStatus::Inactive,
             additional_merchant_data: None,
+            connector_wallets_details: None,
         };
 
         let config_map = kgraph_types::CountryCurrencyFilter {
diff --git a/crates/openapi/src/openapi.rs b/crates/openapi/src/openapi.rs
index b626b7d4418..3d56a42222f 100644
--- a/crates/openapi/src/openapi.rs
+++ b/crates/openapi/src/openapi.rs
@@ -271,6 +271,7 @@ Never share your secret api keys. Keep them guarded and secure.
         api_models::enums::UIWidgetFormLayout,
         api_models::admin::MerchantConnectorCreate,
         api_models::admin::AdditionalMerchantData,
+        api_models::admin::ConnectorWalletDetails,
         api_models::admin::MerchantRecipientData,
         api_models::admin::MerchantAccountData,
         api_models::admin::MerchantConnectorUpdate,
@@ -408,6 +409,8 @@ Never share your secret api keys. Keep them guarded and secure.
         api_models::payments::GpayTokenizationData,
         api_models::payments::GooglePayPaymentMethodInfo,
         api_models::payments::ApplePayWalletData,
+        api_models::payments::SamsungPayWalletCredentials,
+        api_models::payments::SamsungPayTokenData,
         api_models::payments::ApplepayPaymentMethod,
         api_models::payments::PaymentsCancelRequest,
         api_models::payments::PaymentListConstraints,
@@ -429,6 +432,11 @@ Never share your secret api keys. Keep them guarded and secure.
         api_models::payments::GooglePayRedirectData,
         api_models::payments::GooglePayThirdPartySdk,
         api_models::payments::GooglePaySessionResponse,
+        api_models::payments::SamsungPaySessionTokenResponse,
+        api_models::payments::SamsungPayMerchantPaymentInformation,
+        api_models::payments::SamsungPayAmountDetails,
+        api_models::payments::SamsungPayAmountFormat,
+        api_models::payments::SamsungPayProtocolType,
         api_models::payments::GpayShippingAddressParameters,
         api_models::payments::GpayBillingAddressParameters,
         api_models::payments::GpayBillingAddressFormat,
diff --git a/crates/openapi/src/openapi_v2.rs b/crates/openapi/src/openapi_v2.rs
index f12d6a7b567..0dbf5f9cdcf 100644
--- a/crates/openapi/src/openapi_v2.rs
+++ b/crates/openapi/src/openapi_v2.rs
@@ -197,6 +197,7 @@ Never share your secret api keys. Keep them guarded and secure.
         api_models::enums::UIWidgetFormLayout,
         api_models::admin::MerchantConnectorCreate,
         api_models::admin::AdditionalMerchantData,
+        api_models::admin::ConnectorWalletDetails,
         api_models::admin::MerchantRecipientData,
         api_models::admin::MerchantAccountData,
         api_models::admin::MerchantConnectorUpdate,
@@ -335,6 +336,13 @@ Never share your secret api keys. Keep them guarded and secure.
         api_models::payments::GooglePayPaymentMethodInfo,
         api_models::payments::ApplePayWalletData,
         api_models::payments::ApplepayPaymentMethod,
+        api_models::payments::SamsungPaySessionTokenResponse,
+        api_models::payments::SamsungPayMerchantPaymentInformation,
+        api_models::payments::SamsungPayAmountDetails,
+        api_models::payments::SamsungPayAmountFormat,
+        api_models::payments::SamsungPayProtocolType,
+        api_models::payments::SamsungPayWalletCredentials,
+        api_models::payments::SamsungPayTokenData,
         api_models::payments::PaymentsCancelRequest,
         api_models::payments::PaymentListConstraints,
         api_models::payments::PaymentListResponse,
diff --git a/crates/router/src/connector/adyen/transformers.rs b/crates/router/src/connector/adyen/transformers.rs
index e915d05c358..1d49a99106e 100644
--- a/crates/router/src/connector/adyen/transformers.rs
+++ b/crates/router/src/connector/adyen/transformers.rs
@@ -2083,7 +2083,7 @@ impl<'a> TryFrom<(&domain::WalletData, &types::PaymentsAuthorizeRouterData)>
             domain::WalletData::SamsungPay(samsung_data) => {
                 let data = SamsungPayPmData {
                     payment_type: PaymentType::Samsungpay,
-                    samsung_pay_token: samsung_data.token.to_owned(),
+                    samsung_pay_token: samsung_data.payment_credential.token_data.data.to_owned(),
                 };
                 Ok(AdyenPaymentMethod::SamsungPay(Box::new(data)))
             }
diff --git a/crates/router/src/connector/cybersource/transformers.rs b/crates/router/src/connector/cybersource/transformers.rs
index fc35cab773a..e83e5c33052 100644
--- a/crates/router/src/connector/cybersource/transformers.rs
+++ b/crates/router/src/connector/cybersource/transformers.rs
@@ -436,12 +436,27 @@ pub struct FluidData {
 
 pub const FLUID_DATA_DESCRIPTOR: &str = "RklEPUNPTU1PTi5BUFBMRS5JTkFQUC5QQVlNRU5U";
 
+pub const FLUID_DATA_DESCRIPTOR_FOR_SAMSUNG_PAY: &str = "FID=COMMON.SAMSUNG.INAPP.PAYMENT";
+
 #[derive(Debug, Serialize)]
 #[serde(rename_all = "camelCase")]
 pub struct GooglePayPaymentInformation {
     fluid_data: FluidData,
 }
 
+#[derive(Debug, Serialize)]
+#[serde(rename_all = "camelCase")]
+pub struct SamsungPayTokenizedCard {
+    transaction_type: TransactionType,
+}
+
+#[derive(Debug, Serialize)]
+#[serde(rename_all = "camelCase")]
+pub struct SamsungPayPaymentInformation {
+    fluid_data: FluidData,
+    tokenized_card: SamsungPayTokenizedCard,
+}
+
 #[derive(Debug, Serialize)]
 #[serde(untagged)]
 pub enum PaymentInformation {
@@ -450,6 +465,7 @@ pub enum PaymentInformation {
     ApplePay(Box<ApplePayPaymentInformation>),
     ApplePayToken(Box<ApplePayTokenPaymentInformation>),
     MandatePayment(Box<MandatePaymentInformation>),
+    SamsungPay(Box<SamsungPayPaymentInformation>),
     NetworkToken(Box<NetworkTokenPaymentInformation>),
 }
 
@@ -504,12 +520,15 @@ pub struct AdditionalAmount {
 pub enum PaymentSolution {
     ApplePay,
     GooglePay,
+    SamsungPay,
 }
 
 #[derive(Debug, Serialize)]
 pub enum TransactionType {
     #[serde(rename = "1")]
     ApplePay,
+    #[serde(rename = "1")]
+    SamsungPay,
 }
 
 impl From<PaymentSolution> for String {
@@ -517,6 +536,7 @@ impl From<PaymentSolution> for String {
         let payment_solution = match solution {
             PaymentSolution::ApplePay => "001",
             PaymentSolution::GooglePay => "012",
+            PaymentSolution::SamsungPay => "008",
         };
         payment_solution.to_string()
     }
@@ -575,7 +595,7 @@ impl
         let mut commerce_indicator = solution
             .as_ref()
             .map(|pm_solution| match pm_solution {
-                PaymentSolution::ApplePay => network
+                PaymentSolution::ApplePay | PaymentSolution::SamsungPay => network
                     .as_ref()
                     .map(|card_network| match card_network.to_lowercase().as_str() {
                         "amex" => "aesk",
@@ -1491,6 +1511,66 @@ impl
     }
 }
 
+impl
+    TryFrom<(
+        &CybersourceRouterData<&types::PaymentsAuthorizeRouterData>,
+        Box<domain::SamsungPayWalletData>,
+    )> for CybersourcePaymentsRequest
+{
+    type Error = error_stack::Report<errors::ConnectorError>;
+    fn try_from(
+        (item, samsung_pay_data): (
+            &CybersourceRouterData<&types::PaymentsAuthorizeRouterData>,
+            Box<domain::SamsungPayWalletData>,
+        ),
+    ) -> Result<Self, Self::Error> {
+        let email = item
+            .router_data
+            .get_billing_email()
+            .or(item.router_data.request.get_email())?;
+        let bill_to = build_bill_to(item.router_data.get_optional_billing(), email)?;
+        let order_information = OrderInformationWithBill::from((item, Some(bill_to)));
+
+        let payment_information =
+            PaymentInformation::SamsungPay(Box::new(SamsungPayPaymentInformation {
+                fluid_data: FluidData {
+                    value: Secret::from(
+                        consts::BASE64_ENGINE
+                            .encode(samsung_pay_data.payment_credential.token_data.data.peek()),
+                    ),
+                    descriptor: Some(
+                        consts::BASE64_ENGINE.encode(FLUID_DATA_DESCRIPTOR_FOR_SAMSUNG_PAY),
+                    ),
+                },
+                tokenized_card: SamsungPayTokenizedCard {
+                    transaction_type: TransactionType::SamsungPay,
+                },
+            }));
+
+        let processing_information = ProcessingInformation::try_from((
+            item,
+            Some(PaymentSolution::SamsungPay),
+            Some(samsung_pay_data.payment_credential.card_brand),
+        ))?;
+        let client_reference_information = ClientReferenceInformation::from(item);
+        let merchant_defined_information = item
+            .router_data
+            .request
+            .metadata
+            .clone()
+            .map(Vec::<MerchantDefinedInformation>::foreign_from);
+
+        Ok(Self {
+            processing_information,
+            payment_information,
+            order_information,
+            client_reference_information,
+            consumer_authentication_information: None,
+            merchant_defined_information,
+        })
+    }
+}
+
 impl TryFrom<&CybersourceRouterData<&types::PaymentsAuthorizeRouterData>>
     for CybersourcePaymentsRequest
 {
@@ -1588,6 +1668,9 @@ impl TryFrom<&CybersourceRouterData<&types::PaymentsAuthorizeRouterData>>
                         domain::WalletData::GooglePay(google_pay_data) => {
                             Self::try_from((item, google_pay_data))
                         }
+                        domain::WalletData::SamsungPay(samsung_pay_data) => {
+                            Self::try_from((item, samsung_pay_data))
+                        }
                         domain::WalletData::AliPayQr(_)
                         | domain::WalletData::AliPayRedirect(_)
                         | domain::WalletData::AliPayHkRedirect(_)
@@ -1604,7 +1687,6 @@ impl TryFrom<&CybersourceRouterData<&types::PaymentsAuthorizeRouterData>>
                         | domain::WalletData::MobilePayRedirect(_)
                         | domain::WalletData::PaypalRedirect(_)
                         | domain::WalletData::PaypalSdk(_)
-                        | domain::WalletData::SamsungPay(_)
                         | domain::WalletData::TwintRedirect {}
                         | domain::WalletData::VippsRedirect {}
                         | domain::WalletData::TouchNGoRedirect(_)
diff --git a/crates/router/src/core/admin.rs b/crates/router/src/core/admin.rs
index 95b02f0cdb3..19b44a2bf8e 100644
--- a/crates/router/src/core/admin.rs
+++ b/crates/router/src/core/admin.rs
@@ -2125,10 +2125,14 @@ impl MerchantConnectorAccountUpdateBridge for api_models::admin::MerchantConnect
             } else {
                 None
             },
-            connector_wallets_details: helpers::get_encrypted_apple_pay_connector_wallets_details(
-                state, &key_store, &metadata,
-            )
-            .await?,
+            connector_wallets_details:
+                helpers::get_encrypted_connector_wallets_details_with_apple_pay_certificates(
+                    state,
+                    &key_store,
+                    &metadata,
+                    &self.connector_wallets_details,
+                )
+                .await?,
         })
     }
 }
@@ -2302,10 +2306,14 @@ impl MerchantConnectorAccountUpdateBridge for api_models::admin::MerchantConnect
             } else {
                 None
             },
-            connector_wallets_details: helpers::get_encrypted_apple_pay_connector_wallets_details(
-                state, &key_store, &metadata,
-            )
-            .await?,
+            connector_wallets_details:
+                helpers::get_encrypted_connector_wallets_details_with_apple_pay_certificates(
+                    state,
+                    &key_store,
+                    &metadata,
+                    &self.connector_wallets_details,
+                )
+                .await?,
         })
     }
 }
@@ -2436,7 +2444,7 @@ impl MerchantConnectorAccountCreateBridge for api::MerchantConnectorCreate {
             applepay_verified_domains: None,
             pm_auth_config: self.pm_auth_config.clone(),
             status: connector_status,
-            connector_wallets_details: helpers::get_encrypted_apple_pay_connector_wallets_details(state, &key_store, &self.metadata).await?,
+            connector_wallets_details: helpers::get_encrypted_connector_wallets_details_with_apple_pay_certificates(state, &key_store, &self.metadata, &self.connector_wallets_details).await?,
             additional_merchant_data: if let Some(mcd) =  merchant_recipient_data {
                 Some(domain_types::crypto_operation(
                     key_manager_state,
@@ -2601,7 +2609,7 @@ impl MerchantConnectorAccountCreateBridge for api::MerchantConnectorCreate {
             applepay_verified_domains: None,
             pm_auth_config: self.pm_auth_config.clone(),
             status: connector_status,
-            connector_wallets_details: helpers::get_encrypted_apple_pay_connector_wallets_details(state, &key_store, &self.metadata).await?,
+            connector_wallets_details: helpers::get_encrypted_connector_wallets_details_with_apple_pay_certificates(state, &key_store, &self.metadata, &self.connector_wallets_details).await?,
             test_mode: self.test_mode,
             business_country: self.business_country,
             business_label: self.business_label.clone(),
diff --git a/crates/router/src/core/connector_onboarding/paypal.rs b/crates/router/src/core/connector_onboarding/paypal.rs
index 0dca02bf79d..88e1eb80618 100644
--- a/crates/router/src/core/connector_onboarding/paypal.rs
+++ b/crates/router/src/core/connector_onboarding/paypal.rs
@@ -162,6 +162,7 @@ pub async fn update_mca(
         pm_auth_config: None,
         test_mode: None,
         additional_merchant_data: None,
+        connector_wallets_details: None,
     };
     #[cfg(feature = "v2")]
     let request = MerchantConnectorUpdate {
@@ -177,6 +178,7 @@ pub async fn update_mca(
         pm_auth_config: None,
         merchant_id: merchant_id.clone(),
         additional_merchant_data: None,
+        connector_wallets_details: None,
     };
     let mca_response =
         admin::update_connector(state.clone(), &merchant_id, None, &connector_id, request).await?;
diff --git a/crates/router/src/core/errors/utils.rs b/crates/router/src/core/errors/utils.rs
index d2812447ed8..847aef2ba3b 100644
--- a/crates/router/src/core/errors/utils.rs
+++ b/crates/router/src/core/errors/utils.rs
@@ -185,6 +185,7 @@ impl<T> ConnectorErrorExt<T> for error_stack::Result<T, errors::ConnectorError>
             | errors::ConnectorError::FailedToObtainAuthType
             | errors::ConnectorError::FailedToObtainCertificate
             | errors::ConnectorError::NoConnectorMetaData
+            | errors::ConnectorError::NoConnectorWalletDetails
             | errors::ConnectorError::FailedToObtainCertificateKey
             | errors::ConnectorError::FlowNotSupported { .. }
             | errors::ConnectorError::CaptureMethodNotSupported
@@ -284,7 +285,7 @@ impl<T> ConnectorErrorExt<T> for error_stack::Result<T, errors::ConnectorError>
                 errors::ConnectorError::InvalidWallet |
                 errors::ConnectorError::ResponseHandlingFailed |
                 errors::ConnectorError::FailedToObtainCertificate |
-                errors::ConnectorError::NoConnectorMetaData |
+                errors::ConnectorError::NoConnectorMetaData | errors::ConnectorError::NoConnectorWalletDetails |
                 errors::ConnectorError::FailedToObtainCertificateKey |
                 errors::ConnectorError::CaptureMethodNotSupported |
                 errors::ConnectorError::MissingConnectorMandateID |
@@ -370,6 +371,7 @@ impl<T> ConnectorErrorExt<T> for error_stack::Result<T, errors::ConnectorError>
                 | errors::ConnectorError::FailedToObtainAuthType
                 | errors::ConnectorError::FailedToObtainCertificate
                 | errors::ConnectorError::NoConnectorMetaData
+                | errors::ConnectorError::NoConnectorWalletDetails
                 | errors::ConnectorError::FailedToObtainCertificateKey
                 | errors::ConnectorError::NotImplemented(_)
                 | errors::ConnectorError::NotSupported { .. }
diff --git a/crates/router/src/core/payments/flows/session_flow.rs b/crates/router/src/core/payments/flows/session_flow.rs
index 54d8dc230c7..6159776a551 100644
--- a/crates/router/src/core/payments/flows/session_flow.rs
+++ b/crates/router/src/core/payments/flows/session_flow.rs
@@ -496,6 +496,62 @@ async fn create_applepay_session_token(
     }
 }
 
+fn create_samsung_pay_session_token(
+    router_data: &types::PaymentsSessionRouterData,
+    header_payload: api_models::payments::HeaderPayload,
+) -> RouterResult<types::PaymentsSessionRouterData> {
+    let samsung_pay_wallet_details = router_data
+        .connector_wallets_details
+        .clone()
+        .parse_value::<payment_types::SamsungPaySessionTokenData>("SamsungPaySessionTokenData")
+        .change_context(errors::ConnectorError::NoConnectorWalletDetails)
+        .change_context(errors::ApiErrorResponse::InvalidDataFormat {
+            field_name: "connector_wallets_details".to_string(),
+            expected_format: "samsung_pay_metadata_format".to_string(),
+        })?;
+
+    let required_amount_type = StringMajorUnitForConnector;
+    let samsung_pay_amount = required_amount_type
+        .convert(
+            router_data.request.minor_amount,
+            router_data.request.currency,
+        )
+        .change_context(errors::ApiErrorResponse::PreconditionFailed {
+            message: "Failed to convert amount to string major unit for Samsung Pay".to_string(),
+        })?;
+
+    let merchant_domain = header_payload
+        .x_merchant_domain
+        .get_required_value("samsung pay domain")
+        .attach_printable("Failed to get domain for samsung pay session call")?;
+
+    Ok(types::PaymentsSessionRouterData {
+        response: Ok(types::PaymentsResponseData::SessionResponse {
+            session_token: payment_types::SessionToken::SamsungPay(Box::new(
+                payment_types::SamsungPaySessionTokenResponse {
+                    version: "2".to_string(),
+                    service_id: samsung_pay_wallet_details.data.service_id,
+                    order_number: router_data.payment_id.clone(),
+                    merchant_payment_information:
+                        payment_types::SamsungPayMerchantPaymentInformation {
+                            name: samsung_pay_wallet_details.data.merchant_display_name,
+                            url: merchant_domain,
+                            country_code: samsung_pay_wallet_details.data.merchant_business_country,
+                        },
+                    amount: payment_types::SamsungPayAmountDetails {
+                        amount_format: payment_types::SamsungPayAmountFormat::FormatTotalPriceOnly,
+                        currency_code: router_data.request.currency,
+                        total_amount: samsung_pay_amount,
+                    },
+                    protocol: payment_types::SamsungPayProtocolType::Protocol3ds,
+                    allowed_brands: samsung_pay_wallet_details.data.allowed_brands,
+                },
+            )),
+        }),
+        ..router_data.clone()
+    })
+}
+
 fn get_session_request_for_simplified_apple_pay(
     apple_pay_merchant_identifier: String,
     session_token_data: payment_types::SessionTokenForSimplifiedApplePay,
@@ -881,6 +937,9 @@ impl RouterDataSession for types::PaymentsSessionRouterData {
             api::GetToken::GpayMetadata => {
                 create_gpay_session_token(state, self, connector, business_profile)
             }
+            api::GetToken::SamsungPayMetadata => {
+                create_samsung_pay_session_token(self, header_payload)
+            }
             api::GetToken::ApplePayMetadata => {
                 create_applepay_session_token(
                     state,
diff --git a/crates/router/src/core/payments/helpers.rs b/crates/router/src/core/payments/helpers.rs
index 81d9130db85..7447323d9f0 100644
--- a/crates/router/src/core/payments/helpers.rs
+++ b/crates/router/src/core/payments/helpers.rs
@@ -4467,30 +4467,34 @@ pub fn is_apple_pay_simplified_flow(
     ))
 }
 
-pub async fn get_encrypted_apple_pay_connector_wallets_details(
+// This function will return the encrypted connector wallets details with Apple Pay certificates
+// Currently apple pay certifiactes are stored in the metadata which is not encrypted.
+// In future we want those certificates to be encrypted and stored in the connector_wallets_details.
+// As part of migration fallback this function checks apple pay details are present in connector_wallets_details
+// If yes, it will encrypt connector_wallets_details and store it in the database.
+// If no, it will check if apple pay details are present in metadata and merge it with connector_wallets_details, encrypt and store it.
+pub async fn get_encrypted_connector_wallets_details_with_apple_pay_certificates(
     state: &SessionState,
     key_store: &domain::MerchantKeyStore,
     connector_metadata: &Option<masking::Secret<tera::Value>>,
+    connector_wallets_details_optional: &Option<api_models::admin::ConnectorWalletDetails>,
 ) -> RouterResult<Option<Encryptable<masking::Secret<serde_json::Value>>>> {
-    let apple_pay_metadata = get_applepay_metadata(connector_metadata.clone())
-        .map_err(|error| {
-            logger::error!(
-                "Apple pay metadata parsing failed in get_encrypted_apple_pay_connector_wallets_details {:?}",
-                error
-            )
-        })
-        .ok();
+    let connector_wallet_details_with_apple_pay_metadata_optional =
+        get_apple_pay_metadata_if_needed(connector_metadata, connector_wallets_details_optional)
+            .await?;
 
-    let connector_apple_pay_details = apple_pay_metadata
-        .map(|metadata| {
-            serde_json::to_value(metadata)
+    let connector_wallets_details = connector_wallet_details_with_apple_pay_metadata_optional
+        .map(|details| {
+            serde_json::to_value(details)
                 .change_context(errors::ApiErrorResponse::InternalServerError)
-                .attach_printable("Failed to serialize apple pay metadata as JSON")
+                .attach_printable("Failed to serialize Apple Pay metadata as JSON")
         })
         .transpose()?
         .map(masking::Secret::new);
+
     let key_manager_state: KeyManagerState = state.into();
-    let encrypted_connector_apple_pay_details = connector_apple_pay_details
+    let encrypted_connector_wallets_details = connector_wallets_details
+        .clone()
         .async_lift(|wallets_details| async {
             types::crypto_operation(
                 &key_manager_state,
@@ -4505,7 +4509,86 @@ pub async fn get_encrypted_apple_pay_connector_wallets_details(
         .await
         .change_context(errors::ApiErrorResponse::InternalServerError)
         .attach_printable("Failed while encrypting connector wallets details")?;
-    Ok(encrypted_connector_apple_pay_details)
+
+    Ok(encrypted_connector_wallets_details)
+}
+
+async fn get_apple_pay_metadata_if_needed(
+    connector_metadata: &Option<masking::Secret<tera::Value>>,
+    connector_wallets_details_optional: &Option<api_models::admin::ConnectorWalletDetails>,
+) -> RouterResult<Option<api_models::admin::ConnectorWalletDetails>> {
+    if let Some(connector_wallets_details) = connector_wallets_details_optional {
+        if connector_wallets_details.apple_pay_combined.is_some()
+            || connector_wallets_details.apple_pay.is_some()
+        {
+            return Ok(Some(connector_wallets_details.clone()));
+        }
+        // Otherwise, merge Apple Pay metadata
+        return get_and_merge_apple_pay_metadata(
+            connector_metadata.clone(),
+            Some(connector_wallets_details.clone()),
+        )
+        .await;
+    }
+
+    // If connector_wallets_details_optional is None, attempt to get Apple Pay metadata
+    get_and_merge_apple_pay_metadata(connector_metadata.clone(), None).await
+}
+
+async fn get_and_merge_apple_pay_metadata(
+    connector_metadata: Option<masking::Secret<tera::Value>>,
+    connector_wallets_details_optional: Option<api_models::admin::ConnectorWalletDetails>,
+) -> RouterResult<Option<api_models::admin::ConnectorWalletDetails>> {
+    let apple_pay_metadata_optional = get_applepay_metadata(connector_metadata)
+        .map_err(|error| {
+            logger::error!(
+                "Apple Pay metadata parsing failed in get_encrypted_connector_wallets_details_with_apple_pay_certificates {:?}",
+                error
+            );
+        })
+        .ok();
+
+    if let Some(apple_pay_metadata) = apple_pay_metadata_optional {
+        let updated_wallet_details = match apple_pay_metadata {
+            api_models::payments::ApplepaySessionTokenMetadata::ApplePayCombined(
+                apple_pay_combined_metadata,
+            ) => {
+                let combined_metadata_json = serde_json::to_value(apple_pay_combined_metadata)
+                    .change_context(errors::ApiErrorResponse::InternalServerError)
+                    .attach_printable("Failed to serialize Apple Pay combined metadata as JSON")?;
+
+                api_models::admin::ConnectorWalletDetails {
+                    apple_pay_combined: Some(masking::Secret::new(combined_metadata_json)),
+                    apple_pay: connector_wallets_details_optional
+                        .as_ref()
+                        .and_then(|d| d.apple_pay.clone()),
+                    samsung_pay: connector_wallets_details_optional
+                        .as_ref()
+                        .and_then(|d| d.samsung_pay.clone()),
+                }
+            }
+            api_models::payments::ApplepaySessionTokenMetadata::ApplePay(apple_pay_metadata) => {
+                let metadata_json = serde_json::to_value(apple_pay_metadata)
+                    .change_context(errors::ApiErrorResponse::InternalServerError)
+                    .attach_printable("Failed to serialize Apple Pay metadata as JSON")?;
+
+                api_models::admin::ConnectorWalletDetails {
+                    apple_pay: Some(masking::Secret::new(metadata_json)),
+                    apple_pay_combined: connector_wallets_details_optional
+                        .as_ref()
+                        .and_then(|d| d.apple_pay_combined.clone()),
+                    samsung_pay: connector_wallets_details_optional
+                        .as_ref()
+                        .and_then(|d| d.samsung_pay.clone()),
+                }
+            }
+        };
+
+        return Ok(Some(updated_wallet_details));
+    }
+
+    // Return connector_wallets_details if no Apple Pay metadata was found
+    Ok(connector_wallets_details_optional)
 }
 
 pub fn get_applepay_metadata(
diff --git a/crates/router/src/core/payments/operations/payment_session.rs b/crates/router/src/core/payments/operations/payment_session.rs
index f12cd71cdb0..1807369a029 100644
--- a/crates/router/src/core/payments/operations/payment_session.rs
+++ b/crates/router/src/core/payments/operations/payment_session.rs
@@ -490,6 +490,7 @@ impl From<api_models::enums::PaymentMethodType> for api::GetToken {
         match value {
             api_models::enums::PaymentMethodType::GooglePay => Self::GpayMetadata,
             api_models::enums::PaymentMethodType::ApplePay => Self::ApplePayMetadata,
+            api_models::enums::PaymentMethodType::SamsungPay => Self::SamsungPayMetadata,
             api_models::enums::PaymentMethodType::Paypal => Self::PaypalSdkMetadata,
             _ => Self::Connector,
         }
diff --git a/crates/router/src/types/api.rs b/crates/router/src/types/api.rs
index 34dea537b2d..dd5e47b1005 100644
--- a/crates/router/src/types/api.rs
+++ b/crates/router/src/types/api.rs
@@ -190,6 +190,7 @@ pub type BoxedConnectorV2 = Box<&'static (dyn ConnectorV2 + Sync)>;
 #[derive(Clone, Eq, PartialEq, Debug)]
 pub enum GetToken {
     GpayMetadata,
+    SamsungPayMetadata,
     ApplePayMetadata,
     PaypalSdkMetadata,
     Connector,
diff --git a/crates/router/src/types/transformers.rs b/crates/router/src/types/transformers.rs
index a6f6d7c4c5a..a503f24d94c 100644
--- a/crates/router/src/types/transformers.rs
+++ b/crates/router/src/types/transformers.rs
@@ -1068,6 +1068,18 @@ impl ForeignTryFrom<domain::MerchantConnectorAccount>
                 })
                 .transpose()?
                 .map(api_models::admin::AdditionalMerchantData::foreign_from),
+            connector_wallets_details: item
+                .connector_wallets_details
+                .map(|data| {
+                    data.into_inner()
+                        .expose()
+                        .parse_value::<api_models::admin::ConnectorWalletDetails>(
+                            "ConnectorWalletDetails",
+                        )
+                        .attach_printable("Unable to deserialize connector_wallets_details")
+                        .change_context(errors::ApiErrorResponse::InternalServerError)
+                })
+                .transpose()?,
         };
         #[cfg(feature = "v2")]
         let response = Self {
@@ -1096,6 +1108,18 @@ impl ForeignTryFrom<domain::MerchantConnectorAccount>
                 })
                 .transpose()?
                 .map(api_models::admin::AdditionalMerchantData::foreign_from),
+            connector_wallets_details: item
+                .connector_wallets_details
+                .map(|data| {
+                    data.into_inner()
+                        .expose()
+                        .parse_value::<api_models::admin::ConnectorWalletDetails>(
+                            "ConnectorWalletDetails",
+                        )
+                        .attach_printable("Unable to deserialize connector_wallets_details")
+                        .change_context(errors::ApiErrorResponse::InternalServerError)
+                })
+                .transpose()?,
         };
         Ok(response)
     }
@@ -1191,6 +1215,18 @@ impl ForeignTryFrom<domain::MerchantConnectorAccount>
                 })
                 .transpose()?
                 .map(api_models::admin::AdditionalMerchantData::foreign_from),
+            connector_wallets_details: item
+                .connector_wallets_details
+                .map(|data| {
+                    data.into_inner()
+                        .expose()
+                        .parse_value::<api_models::admin::ConnectorWalletDetails>(
+                            "ConnectorWalletDetails",
+                        )
+                        .attach_printable("Unable to deserialize connector_wallets_details")
+                        .change_context(errors::ApiErrorResponse::InternalServerError)
+                })
+                .transpose()?,
         };
         #[cfg(feature = "v1")]
         let response = Self {
@@ -1235,6 +1271,18 @@ impl ForeignTryFrom<domain::MerchantConnectorAccount>
                 })
                 .transpose()?
                 .map(api_models::admin::AdditionalMerchantData::foreign_from),
+            connector_wallets_details: item
+                .connector_wallets_details
+                .map(|data| {
+                    data.into_inner()
+                        .expose()
+                        .parse_value::<api_models::admin::ConnectorWalletDetails>(
+                            "ConnectorWalletDetails",
+                        )
+                        .attach_printable("Unable to deserialize connector_wallets_details")
+                        .change_context(errors::ApiErrorResponse::InternalServerError)
+                })
+                .transpose()?,
         };
         Ok(response)
     }

## Type of Change
<!-- Put an `x` in the boxes that apply -->

- [ ] Bugfix
- [x] New feature
- [ ] Enhancement
- [ ] Refactoring
- [ ] Dependency updates
- [ ] Documentation
- [ ] CI/CD

## Description
<!-- Describe your changes in detail -->
This pr is to support for Samsung pay as a payment method.
This pr also adds a new field in merchant connector account create `connector_wallet_details` which is required to collect the required credentials for Samsung Pay. As this column in the data base stores the data in the encrypted format we also want to migrate apple pay certificates from metadata to `connector_wallet_details`, for which we are inserting apple pay details passed in the metadata to connector_wallet_details. 

Once the frontend changes are done to pass the apple pay credentials in the connector_wallet_details this fallback can be removed.

### Additional Changes

- [ ] This PR modifies the API contract
- [ ] This PR modifies the database schema
- [ ] This PR modifies application configuration/environment variables

<!--
Provide links to the files with corresponding changes.

Following are the paths where you can find config files:
1. `config`
2. `crates/router/src/configs`
3. `loadtest/config`
-->


## Motivation and Context
<!--
Why is this change required? What problem does it solve?
If it fixes an open issue, please link to the issue here.

If you don't have an issue, we'd recommend starting with one first so the PR
can focus on the implementation (unless it is an obvious bug or documentation fix
that will have little conversation).
-->


## How did you test it?
<!--
Did you write an integration/unit/API test to verify the code changes?
Or did you test this change manually (provide relevant screenshots)?
-->
Test Samsung Pay flow
-> Enable Samsung Pay payment method for the connector
```
{
    "connector_type": "payment_processor",
    "connector_name": "cybersource",
    "connector_account_details": {
        "auth_type": "SignatureKey",
        "api_secret": "api_secret",
        "key1": "key1",
        "api_key": "api_key"
    },
    "test_mode": true,
    "disabled": false,
    "payment_methods_enabled": [
        {
            "payment_method": "pay_later",
            "payment_method_types": [
                {
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true,
                    "payment_experience": "invoke_sdk_client",
                    "payment_method_type": "klarna"
                }
            ]
        },
        {
            "payment_method": "pay_later",
            "payment_method_types": [
                {
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true,
                    "payment_experience": "redirect_to_url",
                    "payment_method_type": "klarna"
                }
            ]
        },
        {
            "payment_method": "card",
            "payment_method_types": [
                {
                    "payment_method_type": "credit",
                    "payment_experience": null,
                    "card_networks": [
                        "Visa",
                        "Mastercard",
                        "Discover",
                        "DinersClub"
                    ],
                    "accepted_currencies": null,
                    "accepted_countries": null,
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true
                },
                {
                    "payment_method_type": "debit",
                    "payment_experience": null,
                    "card_networks": [
                        "Visa",
                        "Mastercard"
                    ],
                    "accepted_currencies": null,
                    "accepted_countries": null,
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true
                }
            ]
        },
        {
            "payment_method": "bank_debit",
            "payment_method_types": [
                {
                    "payment_method_type": "ach",
                    "recurring_enabled": true,
                    "installment_payment_enabled": true,
                    "minimum_amount": 0,
                    "maximum_amount": 10000
                }
            ]
        },
        {
            "payment_method": "wallet",
            "payment_method_types": [
                {
                    "payment_method_type": "google_pay",
                    "payment_experience": "invoke_sdk_client",
                    "card_networks": null,
                    "accepted_currencies": null,
                    "accepted_countries": null,
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true
                },
                {
                    "payment_method_type": "samsung_pay",
                    "payment_experience": "invoke_sdk_client",
                    "card_networks": null,
                    "accepted_currencies": null,
                    "accepted_countries": null,
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true
                },
                {
                    "payment_method_type": "apple_pay",
                    "payment_experience": "invoke_sdk_client",
                    "card_networks": null,
                    "accepted_currencies": null,
                    "accepted_countries": null,
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true
                },
                {
                    "payment_method_type": "paypal",
                    "payment_experience": "redirect_to_url",
                    "card_networks": null,
                    "accepted_currencies": null,
                    "accepted_countries": null,
                    "minimum_amount": 1,
                    "maximum_amount": 68607706,
                    "recurring_enabled": true,
                    "installment_payment_enabled": true
                }
            ]
        }
    ],
    "connector_wallets_details": {
        "samsung_pay": {
            "service_id": "49400558c67f4a97b3925f",
            "merchant_display_name": "Hyperswitch",
            "merchant_business_country": "IN",
            "allowed_brands": [
                "visa",
                "masterCard",
                "amex",
                "discover"
            ]
        }
    },
    "connector_webhook_details": {
        "merchant_secret": "merchant_secret"
    }
}
```
-> Create a payment
```
curl --location 'http://localhost:8080/payments' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'api-key: dev_cjSDZPveYx7AbdI5cMRMuPKVdteJ7aIi3ULRasYhU89JtFRZWp9BeNn7PQDLQv8W' \
--data '{
  "amount": 100000,
  "currency": "INR",
  "capture_method": "automatic",
  "authentication_type": "no_three_ds",
  "confirm": false,
  "customer_id": "cu_1726743607"
}'
```
```
{
    "payment_id": "pay_on1wv5l8OM8A3VuDe2GN",
    "merchant_id": "merchant_1726725490",
    "status": "requires_payment_method",
    "amount": 100000,
    "net_amount": 100000,
    "amount_capturable": 0,
    "amount_received": null,
    "connector": null,
    "client_secret": "pay_on1wv5l8OM8A3VuDe2GN_secret_o5JrhSWuWKjcUgrvASpi",
    "created": "2024-09-19T11:00:15.562Z",
    "currency": "INR",
    "customer_id": "cu_1726743615",
    "customer": {
        "id": "cu_1726743615",
        "name": null,
        "email": null,
        "phone": null,
        "phone_country_code": null
    },
    "description": null,
    "refunds": null,
    "disputes": null,
    "mandate_id": null,
    "mandate_data": null,
    "setup_future_usage": null,
    "off_session": null,
    "capture_on": null,
    "capture_method": "automatic",
    "payment_method": null,
    "payment_method_data": null,
    "payment_token": null,
    "shipping": null,
    "billing": null,
    "order_details": null,
    "email": null,
    "name": null,
    "phone": null,
    "return_url": null,
    "authentication_type": "no_three_ds",
    "statement_descriptor_name": null,
    "statement_descriptor_suffix": null,
    "next_action": null,
    "cancellation_reason": null,
    "error_code": null,
    "error_message": null,
    "unified_code": null,
    "unified_message": null,
    "payment_experience": null,
    "payment_method_type": null,
    "connector_label": null,
    "business_country": null,
    "business_label": "default",
    "business_sub_label": null,
    "allowed_payment_method_types": null,
    "ephemeral_key": {
        "customer_id": "cu_1726743615",
        "created_at": 1726743615,
        "expires": 1726747215,
        "secret": "epk_3d5ad79c88554ee7bf0748ae18ecd05b"
    },
    "manual_retry_allowed": null,
    "connector_transaction_id": null,
    "frm_message": null,
    "metadata": null,
    "connector_metadata": null,
    "feature_metadata": null,
    "reference_id": null,
    "payment_link": null,
    "profile_id": "pro_XdGC3A6KTKR5n2WDLON5",
    "surcharge_details": null,
    "attempt_count": 1,
    "merchant_decision": null,
    "merchant_connector_id": null,
    "incremental_authorization_allowed": null,
    "authorization_count": null,
    "incremental_authorizations": null,
    "external_authentication_details": null,
    "external_3ds_authentication_attempted": false,
    "expires_on": "2024-09-19T11:15:15.562Z",
    "fingerprint": null,
    "browser_info": null,
    "payment_method_id": null,
    "payment_method_status": null,
    "updated": "2024-09-19T11:00:15.680Z",
    "charges": null,
    "frm_metadata": null,
    "merchant_order_reference_id": null,
    "order_tax_amount": null
}
```
-> Session call
```
curl --location 'http://localhost:8080/payments/session_tokens' \
--header 'Content-Type: application/json' \
--header 'x-browser-name: Safari' \
--header 'x-merchant-domain: sdk-test-app.netlify.app' \
--header 'api-key: pk_dev_c23e25c5054241288a778316e463e309' \
--data '{
    "payment_id": "pay_on1wv5l8OM8A3VuDe2GN",
    "wallets": [],
    "client_secret": "pay_on1wv5l8OM8A3VuDe2GN_secret_o5JrhSWuWKjcUgrvASpi"
}'
```
```
{
    "payment_id": "pay_on1wv5l8OM8A3VuDe2GN",
    "client_secret": "pay_on1wv5l8OM8A3VuDe2GN_secret_o5JrhSWuWKjcUgrvASpi",
    "session_token": [
        {
            "wallet_name": "samsung_pay",
            "version": "2",
            "service_id": "49400558c67f4a97b3925f",
            "order_number": "pay_on1wv5l8OM8A3VuDe2GN",
            "merchant": {
                "name": "Hyperswitch",
                "url": "sdk-test-app.netlify.app",
                "country_code": "IN"
            },
            "amount": {
                "option": "FORMAT_TOTAL_PRICE_ONLY",
                "currency_code": "INR",
                "total": "1000.00"
            },
            "protocol": "PROTOCOL3DS",
            "allowed_brands": [
                "visa",
                "masterCard",
                "amex",
                "discover"
            ]
        }
    ]
}
```
-> Confirm call
```
curl --location 'http://localhost:8080/payments' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'api-key: dev_cjSDZPveYx7AbdI5cMRMuPKVdteJ7aIi3ULRasYhU89JtFRZWp9BeNn7PQDLQv8W' \
--data-raw '{
    "amount": 1,
    "currency": "USD",
    "confirm": true,
    "business_country": "US",
    "business_label": "default",
    "amount_to_capture": 1,
    "customer_id": "custhype123",
    "capture_method": "automatic",
    "capture_on": "2022-09-10T10:11:12Z",
    "return_url": "https://google.com",
    "email": "something@gmail.com",
    "name": "Joseph Doe",
    "phone": "999999999",
    "phone_country_code": "+65",
    "description": "Its my first payment request",
    "statement_descriptor_name": "Juspay",
    "statement_descriptor_suffix": "Router",
    "payment_method": "wallet",
    "payment_method_type": "samsung_pay",
    "billing": {
        "address": {
            "line1": "1467",
            "line2": "Harrison Street",
            "line3": "Harrison Street",
            "city": "San Fransico",
            "state": "California",
            "zip": "94122",
            "country": "US",
            "first_name": "joseph",
            "last_name": "Doe"
        },
        "phone": {
            "number": "8056594427",
            "country_code": "+91"
        }
    },
    "payment_method_data": {
        "wallet": {
            "samsung_pay": {
                "payment_credential": {
                    "card_brand": "visa",
                    "recurring_payment": false,
                    "card_last4digits": "1234",
                    "method": "3DS",
                    "3_d_s": {
                        "type": "S",
                        "version": "100",
                        "data": "encrypted samsung pay data"
                    }
                }
            }
        }
    }
}'
```
```
{
    "payment_id": "pay_0lHEl7IAq7cFn680x4HJ",
    "merchant_id": "merchant_1726725490",
    "status": "failed",
    "amount": 1,
    "net_amount": 1,
    "amount_capturable": 0,
    "amount_received": null,
    "connector": "cybersource",
    "client_secret": "pay_0lHEl7IAq7cFn680x4HJ_secret_3bsNpl8N5rArpWizVWik",
    "created": "2024-09-19T11:28:58.596Z",
    "currency": "USD",
    "customer_id": "custhype123",
    "customer": {
        "id": "custhype123",
        "name": "Joseph Doe",
        "email": "something@gmail.com",
        "phone": "999999999",
        "phone_country_code": "+65"
    },
    "description": "Its my first payment request",
    "refunds": null,
    "disputes": null,
    "mandate_id": null,
    "mandate_data": null,
    "setup_future_usage": null,
    "off_session": null,
    "capture_on": null,
    "capture_method": "automatic",
    "payment_method": "wallet",
    "payment_method_data": {
        "wallet": {},
        "billing": null
    },
    "payment_token": null,
    "shipping": null,
    "billing": {
        "address": {
            "city": "San Fransico",
            "country": "US",
            "line1": "1467",
            "line2": "Harrison Street",
            "line3": "Harrison Street",
            "zip": "94122",
            "state": "California",
            "first_name": "joseph",
            "last_name": "Doe"
        },
        "phone": {
            "number": "8056594427",
            "country_code": "+91"
        },
        "email": null
    },
    "order_details": null,
    "email": "something@gmail.com",
    "name": "Joseph Doe",
    "phone": "999999999",
    "return_url": "https://google.com/",
    "authentication_type": "no_three_ds",
    "statement_descriptor_name": "Juspay",
    "statement_descriptor_suffix": "Router",
    "next_action": null,
    "cancellation_reason": null,
    "error_code": "INVALID_DATA",
    "error_message": "Declined - One or more fields in the request contains invalid data, detailed_error_information: paymentInformation.fluidData.value : INVALID_DATA",
    "unified_code": "UE_000",
    "unified_message": "Something went wrong",
    "payment_experience": null,
    "payment_method_type": "samsung_pay",
    "connector_label": "cybersource_US_default_default",
    "business_country": "US",
    "business_label": "default",
    "business_sub_label": null,
    "allowed_payment_method_types": null,
    "ephemeral_key": {
        "customer_id": "custhype123",
        "created_at": 1726745338,
        "expires": 1726748938,
        "secret": "epk_48f2e9de3ad641578f3df9e9a46d9c80"
    },
    "manual_retry_allowed": true,
    "connector_transaction_id": null,
    "frm_message": null,
    "metadata": null,
    "connector_metadata": null,
    "feature_metadata": null,
    "reference_id": null,
    "payment_link": null,
    "profile_id": "pro_XdGC3A6KTKR5n2WDLON5",
    "surcharge_details": null,
    "attempt_count": 1,
    "merchant_decision": null,
    "merchant_connector_id": "mca_TO5NdOnj3ohWTfxBKGsc",
    "incremental_authorization_allowed": false,
    "authorization_count": null,
    "incremental_authorizations": null,
    "external_authentication_details": null,
    "external_3ds_authentication_attempted": false,
    "expires_on": "2024-09-19T11:43:58.596Z",
    "fingerprint": null,
    "browser_info": null,
    "payment_method_id": null,
    "payment_method_status": null,
    "updated": "2024-09-19T11:29:00.222Z",
    "charges": null,
    "frm_metadata": null,
    "merchant_order_reference_id": null,
    "order_tax_amount": null
}
```
The status will be failed as Samsung does not have a test card and cybersource returns invalid data error for live cards  



## Checklist
<!-- Put an `x` in the boxes that apply -->

- [x] I formatted the code `cargo +nightly fmt --all`
- [x] I addressed lints thrown by `cargo clippy`
- [x] I reviewed the submitted code
- [ ] I added unit tests for my changes where possible
