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
feat(core): store customer_acceptance in the payment_methods table (#3885)
Amisha Prabhata1fd36a1abea
diff --git a/crates/api_models/src/payments.rs b/crates/api_models/src/payments.rsindex ba0d963b8c..86b09f2fa5 100644--- a/crates/api_models/src/payments.rs+++ b/crates/api_models/src/payments.rs@@ -348,9 +348,12 @@ pub struct PaymentsRequest {#[remove_in(PaymentsUpdateRequest, PaymentsCreateRequest)]pub client_secret: Option<String>,- /// Passing this object during payments creates a mandate. The mandate_type sub object is passed by the server usually and the customer_acceptance sub object is usually passed by the SDK or client+ /// Passing this object during payments creates a mandate. The mandate_type sub object is passed by the server.pub mandate_data: Option<MandateData>,+ /// Passing this object during payments confirm . The customer_acceptance sub object is usually passed by the SDK or client+ pub customer_acceptance: Option<CustomerAcceptance>,+/// A unique identifier to link the payment to a mandate. To do Recurring payments after a mandate has been created, pass the mandate_id instead of payment_method_data#[schema(max_length = 255, example = "mandate_iwer89rnjef349dni3")]#[remove_in(PaymentsUpdateRequest)]diff --git a/crates/common_enums/src/enums.rs b/crates/common_enums/src/enums.rsindex ae2fb28aae..f04c52042e 100644--- a/crates/common_enums/src/enums.rs+++ b/crates/common_enums/src/enums.rs@@ -1145,8 +1145,8 @@ pub enum IntentStatus {#[serde(rename_all = "snake_case")]#[strum(serialize_all = "snake_case")]pub enum FutureUsage {- #[default]OffSession,+ #[default]OnSession,}diff --git a/crates/data_models/src/mandates.rs b/crates/data_models/src/mandates.rsindex b4478f84ee..fa22a4e57d 100644--- a/crates/data_models/src/mandates.rs+++ b/crates/data_models/src/mandates.rs@@ -113,6 +113,16 @@ impl From<ApiCustomerAcceptance> for CustomerAcceptance {}}+impl From<CustomerAcceptance> for ApiCustomerAcceptance {+ fn from(value: CustomerAcceptance) -> Self {+ Self {+ acceptance_type: value.acceptance_type.into(),+ accepted_at: value.accepted_at,+ online: value.online.map(|d| d.into()),+ }+ }+}+impl From<ApiAcceptanceType> for AcceptanceType {fn from(value: ApiAcceptanceType) -> Self {match value {@@ -121,6 +131,14 @@ impl From<ApiAcceptanceType> for AcceptanceType {}}}+impl From<AcceptanceType> for ApiAcceptanceType {+ fn from(value: AcceptanceType) -> Self {+ match value {+ AcceptanceType::Online => Self::Online,+ AcceptanceType::Offline => Self::Offline,+ }+ }+}impl From<ApiOnlineMandate> for OnlineMandate {fn from(value: ApiOnlineMandate) -> Self {@@ -130,6 +148,14 @@ impl From<ApiOnlineMandate> for OnlineMandate {}}}+impl From<OnlineMandate> for ApiOnlineMandate {+ fn from(value: OnlineMandate) -> Self {+ Self {+ ip_address: value.ip_address,+ user_agent: value.user_agent,+ }+ }+}impl CustomerAcceptance {pub fn get_ip_address(&self) -> Option<String> {diff --git a/crates/router/src/core/mandate.rs b/crates/router/src/core/mandate.rsindex ec3bb7e429..d07a8814c8 100644--- a/crates/router/src/core/mandate.rs+++ b/crates/router/src/core/mandate.rs@@ -495,4 +495,5 @@ pub trait MandateBehaviour {fn set_mandate_id(&mut self, new_mandate_id: Option<api_models::payments::MandateIds>);fn get_payment_method_data(&self) -> api_models::payments::PaymentMethodData;fn get_setup_mandate_details(&self) -> Option<&data_models::mandates::MandateData>;+ fn get_customer_acceptance(&self) -> Option<api_models::payments::CustomerAcceptance>;}diff --git a/crates/router/src/core/payment_methods/cards.rs b/crates/router/src/core/payment_methods/cards.rsindex ce7f48405e..4fdf957c84 100644--- a/crates/router/src/core/payment_methods/cards.rs+++ b/crates/router/src/core/payment_methods/cards.rs@@ -81,6 +81,7 @@ pub async fn create_payment_method(locker_id: Option<String>,merchant_id: &str,pm_metadata: Option<serde_json::Value>,+ customer_acceptance: Option<serde_json::Value>,payment_method_data: Option<Encryption>,key_store: &domain::MerchantKeyStore,) -> errors::CustomResult<storage::PaymentMethod, errors::ApiErrorResponse> {@@ -100,6 +101,7 @@ pub async fn create_payment_method(scheme: req.card_network.clone(),metadata: pm_metadata.map(masking::Secret::new),payment_method_data,+ customer_acceptance: customer_acceptance.map(masking::Secret::new),..storage::PaymentMethodNew::default()}).await@@ -183,6 +185,7 @@ pub async fn get_or_insert_payment_method(&merchant_account.merchant_id,customer_id,resp.metadata.clone().map(|val| val.expose()),+ None,locker_id,).await@@ -367,6 +370,7 @@ pub async fn add_payment_method(merchant_id,&customer_id,pm_metadata.cloned(),+ None,locker_id,).await?;@@ -385,6 +389,7 @@ pub async fn insert_payment_method(merchant_id: &str,customer_id: &str,pm_metadata: Option<serde_json::Value>,+ customer_acceptance: Option<serde_json::Value>,locker_id: Option<String>,) -> errors::RouterResult<diesel_models::PaymentMethod> {let pm_card_details = resp@@ -400,6 +405,7 @@ pub async fn insert_payment_method(locker_id,merchant_id,pm_metadata,+ customer_acceptance,pm_data_encrypted,key_store,)diff --git a/crates/router/src/core/payments.rs b/crates/router/src/core/payments.rsindex aa44e5db22..002502e9d9 100644--- a/crates/router/src/core/payments.rs+++ b/crates/router/src/core/payments.rs@@ -15,7 +15,7 @@ use std::{fmt::Debug, marker::PhantomData, ops::Deref, time::Instant, vec::IntoIuse api_models::{self, enums, payments::HeaderPayload};use common_utils::{ext_traits::AsyncExt, pii, types::Surcharge};-use data_models::mandates::MandateData;+use data_models::mandates::{CustomerAcceptance, MandateData};use diesel_models::{ephemeral_key, fraud_check::FraudCheck};use error_stack::{IntoReport, ResultExt};use futures::future::join_all;@@ -2050,6 +2050,7 @@ wherepub mandate_connector: Option<MandateConnectorDetails>,pub currency: storage_enums::Currency,pub setup_mandate: Option<MandateData>,+ pub customer_acceptance: Option<CustomerAcceptance>,pub address: PaymentAddress,pub token: Option<String>,pub confirm: Option<bool>,diff --git a/crates/router/src/core/payments/flows/authorize_flow.rs b/crates/router/src/core/payments/flows/authorize_flow.rsindex d7d122c325..cc2540aa22 100644--- a/crates/router/src/core/payments/flows/authorize_flow.rs+++ b/crates/router/src/core/payments/flows/authorize_flow.rs@@ -99,7 +99,6 @@ impl Feature<api::Authorize, types::PaymentsAuthorizeData> for types::PaymentsAumerchant_account,self.request.payment_method_type,key_store,- is_mandate,)).await?;Ok(mandate::mandate_procedure(@@ -131,7 +130,6 @@ impl Feature<api::Authorize, types::PaymentsAuthorizeData> for types::PaymentsAu&merchant_account,self.request.payment_method_type,&key_store,- is_mandate,)).await;@@ -294,6 +292,9 @@ impl mandate::MandateBehaviour for types::PaymentsAuthorizeData {fn set_mandate_id(&mut self, new_mandate_id: Option<api_models::payments::MandateIds>) {self.mandate_id = new_mandate_id;}+ fn get_customer_acceptance(&self) -> Option<api_models::payments::CustomerAcceptance> {+ self.customer_acceptance.clone().map(From::from)+ }}pub async fn authorize_preprocessing_steps<F: Clone>(diff --git a/crates/router/src/core/payments/flows/setup_mandate_flow.rs b/crates/router/src/core/payments/flows/setup_mandate_flow.rsindex 3f43204b98..71d4398933 100644--- a/crates/router/src/core/payments/flows/setup_mandate_flow.rs+++ b/crates/router/src/core/payments/flows/setup_mandate_flow.rs@@ -98,7 +98,7 @@ impl Feature<api::SetupMandate, types::SetupMandateRequestData> for types::Setup).await.to_setup_mandate_failed_response()?;- let is_mandate = resp.request.setup_mandate_details.is_some();+let pm_id = Box::pin(tokenization::save_payment_method(state,connector,@@ -107,7 +107,6 @@ impl Feature<api::SetupMandate, types::SetupMandateRequestData> for types::Setupmerchant_account,self.request.payment_method_type,key_store,- is_mandate,)).await?;mandate::mandate_procedure(@@ -234,8 +233,6 @@ impl types::SetupMandateRouterData {let payment_method_type = self.request.payment_method_type;- let is_mandate = resp.request.setup_mandate_details.is_some();-let pm_id = Box::pin(tokenization::save_payment_method(state,connector,@@ -244,7 +241,6 @@ impl types::SetupMandateRouterData {merchant_account,payment_method_type,key_store,- is_mandate,)).await?;@@ -320,7 +316,6 @@ impl types::SetupMandateRouterData {).await.to_setup_mandate_failed_response()?;- let is_mandate = resp.request.setup_mandate_details.is_some();let pm_id = Box::pin(tokenization::save_payment_method(state,connector,@@ -329,7 +324,6 @@ impl types::SetupMandateRouterData {merchant_account,self.request.payment_method_type,key_store,- is_mandate,)).await?;let mandate = state@@ -430,6 +424,9 @@ impl mandate::MandateBehaviour for types::SetupMandateRequestData {fn get_setup_mandate_details(&self) -> Option<&data_models::mandates::MandateData> {self.setup_mandate_details.as_ref()}+ fn get_customer_acceptance(&self) -> Option<api_models::payments::CustomerAcceptance> {+ self.customer_acceptance.clone().map(From::from)+ }}impl TryFrom<types::SetupMandateRequestData> for types::PaymentMethodTokenizationData {diff --git a/crates/router/src/core/payments/helpers.rs b/crates/router/src/core/payments/helpers.rsindex d158a4bc94..eb476cfccd 100644--- a/crates/router/src/core/payments/helpers.rs+++ b/crates/router/src/core/payments/helpers.rs@@ -825,16 +825,6 @@ fn validate_new_mandate_request(.clone().get_required_value("mandate_data")?;- if api_enums::FutureUsage::OnSession- == req- .setup_future_usage- .get_required_value("setup_future_usage")?- {- Err(report!(errors::ApiErrorResponse::PreconditionFailed {- message: "`setup_future_usage` must be `off_session` for mandates".into()- }))?- };-// Only use this validation if the customer_acceptance is presentif mandate_data.customer_acceptance@@ -3862,3 +3852,17 @@ pub fn validate_session_expiry(session_expiry: u32) -> Result<(), errors::ApiErrOk(())}}++// This function validates the mandate_data with its setup_future_usage+pub fn validate_mandate_data_and_future_usage(+ setup_future_usages: Option<api_enums::FutureUsage>,+ mandate_details_present: bool,+) -> Result<(), errors::ApiErrorResponse> {+ if Some(api_enums::FutureUsage::OnSession) == setup_future_usages && mandate_details_present {+ Err(errors::ApiErrorResponse::PreconditionFailed {+ message: "`setup_future_usage` must be `off_session` for mandates".into(),+ })+ } else {+ Ok(())+ }+}diff --git a/crates/router/src/core/payments/operations/payment_approve.rs b/crates/router/src/core/payments/operations/payment_approve.rsindex caca29d8e2..a38c7bbdd3 100644--- a/crates/router/src/core/payments/operations/payment_approve.rs+++ b/crates/router/src/core/payments/operations/payment_approve.rs@@ -147,6 +147,7 @@ impl<F: Send + Clone, Ctx: PaymentMethodRetrieve>mandate_id: None,mandate_connector: None,setup_mandate: None,+ customer_acceptance: None,token: None,address: PaymentAddress {shipping: shipping_address.as_ref().map(|a| a.into()),diff --git a/crates/router/src/core/payments/operations/payment_cancel.rs b/crates/router/src/core/payments/operations/payment_cancel.rsindex 097b7ab40e..1b09e9abce 100644--- a/crates/router/src/core/payments/operations/payment_cancel.rs+++ b/crates/router/src/core/payments/operations/payment_cancel.rs@@ -155,6 +155,7 @@ impl<F: Send + Clone, Ctx: PaymentMethodRetrieve>mandate_id: None,mandate_connector: None,setup_mandate: None,+ customer_acceptance: None,token: None,address: PaymentAddress {shipping: shipping_address.as_ref().map(|a| a.into()),diff --git a/crates/router/src/core/payments/operations/payment_capture.rs b/crates/router/src/core/payments/operations/payment_capture.rsindex e9d520e4ab..4a488a07eb 100644--- a/crates/router/src/core/payments/operations/payment_capture.rs+++ b/crates/router/src/core/payments/operations/payment_capture.rs@@ -200,6 +200,7 @@ impl<F: Send + Clone, Ctx: PaymentMethodRetrieve>mandate_id: None,mandate_connector: None,setup_mandate: None,+ customer_acceptance: None,token: None,address: payments::PaymentAddress {shipping: shipping_address.as_ref().map(|a| a.into()),diff --git a/crates/router/src/core/payments/operations/payment_complete_authorize.rs b/crates/router/src/core/payments/operations/payment_complete_authorize.rsindex f7e7598cf7..395f8e59db 100644--- a/crates/router/src/core/payments/operations/payment_complete_authorize.rs+++ b/crates/router/src/core/payments/operations/payment_complete_authorize.rs@@ -215,6 +215,12 @@ impl<F: Send + Clone, Ctx: PaymentMethodRetrieve>// The operation merges mandate data from both request and payment_attemptlet setup_mandate = setup_mandate.map(Into::into);+ let mandate_details_present =+ payment_attempt.mandate_details.is_some() || request.mandate_data.is_some();+ helpers::validate_mandate_data_and_future_usage(+ payment_intent.setup_future_usage,+ mandate_details_present,+ )?;let profile_id = payment_intent.profile_id.as_ref()@@ -239,6 +245,7 @@ impl<F: Send + Clone, Ctx: PaymentMethodRetrieve>mandate_id: None,mandate_connector,setup_mandate,+ customer_acceptance: None,token,address: PaymentAddress {shipping: shipping_address.as_ref().map(|a| a.into()),diff --git a/crates/router/src/core/payments/operations/payment_confirm.rs b/crates/router/src/core/payments/operations/payment_confirm.rsindex 111f1bed29..529565c71e 100644--- a/crates/router/src/core/payments/operations/payment_confirm.rs+++ b/crates/router/src/core/payments/operations/payment_confirm.rs@@ -361,6 +361,7 @@ impl<F: Send + Clone, Ctx: PaymentMethodRetrieve>.change_context(errors::ApiErrorResponse::InvalidDataValue {field_name: "browser_info",})?;+ let customer_acceptance = request.customer_acceptance.clone().map(From::from);helpers::validate_card_data(request@@ -461,6 +462,12 @@ impl<F: Send + Clone, Ctx: PaymentMethodRetrieve>sm});+ let mandate_details_present =+ payment_attempt.mandate_details.is_some() || request.mandate_data.is_some();+ helpers::validate_mandate_data_and_future_usage(+ payment_intent.setup_future_usage,+ mandate_details_present,+ )?;let n_request_payment_method_data = request.payment_method_data.as_ref()@@ -539,6 +546,7 @@ impl<F: Send + Clone, Ctx: PaymentMethodRetrieve>mandate_id: None,mandate_connector,setup_mandate,+ customer_acceptance,token,address: PaymentAddress {shipping: shipping_address.as_ref().map(|a| a.into()),diff --git a/crates/router/src/core/payments/operations/payment_create.rs b/crates/router/src/core/payments/operations/payment_create.rsindex 3ba7092aea..5ec8bfaf55 100644--- a/crates/router/src/core/payments/operations/payment_create.rs+++ b/crates/router/src/core/payments/operations/payment_create.rs@@ -281,6 +281,12 @@ impl<F: Send + Clone, Ctx: PaymentMethodRetrieve>.to_duplicate_response(errors::ApiErrorResponse::DuplicatePayment {payment_id: payment_id.clone(),})?;+ let mandate_details_present = payment_attempt.mandate_details.is_some();++ helpers::validate_mandate_data_and_future_usage(+ request.setup_future_usage,+ mandate_details_present,+ )?;// connector mandate reference update historylet mandate_id = request.mandate_id@@ -355,6 +361,8 @@ impl<F: Send + Clone, Ctx: PaymentMethodRetrieve>// The operation merges mandate data from both request and payment_attemptlet setup_mandate = setup_mandate.map(MandateData::from);+ let customer_acceptance = request.customer_acceptance.clone().map(From::from);+let surcharge_details = request.surcharge_details.map(|request_surcharge_details| {payments::types::SurchargeDetails::from((&request_surcharge_details, &payment_attempt))});@@ -368,6 +376,7 @@ impl<F: Send + Clone, Ctx: PaymentMethodRetrieve>.payment_method_data.apply_additional_payment_data(additional_payment_data)});+let amount = payment_attempt.get_total_amount().into();let payment_data = PaymentData {flow: PhantomData,@@ -379,6 +388,7 @@ impl<F: Send + Clone, Ctx: PaymentMethodRetrieve>mandate_id,mandate_connector,setup_mandate,+ customer_acceptance,token,address: PaymentAddress {shipping: shipping_address.as_ref().map(|a| a.into()),diff --git a/crates/router/src/core/payments/operations/payment_reject.rs b/crates/router/src/core/payments/operations/payment_reject.rsindex 281ffdd06f..a1416ea190 100644--- a/crates/router/src/core/payments/operations/payment_reject.rs+++ b/crates/router/src/core/payments/operations/payment_reject.rs@@ -143,6 +143,7 @@ impl<F: Send + Clone, Ctx: PaymentMethodRetrieve>mandate_id: None,mandate_connector: None,setup_mandate: None,+ customer_acceptance: None,token: None,address: PaymentAddress {shipping: shipping_address.as_ref().map(|a| a.into()),diff --git a/crates/router/src/core/payments/operations/payment_session.rs b/crates/router/src/core/payments/operations/payment_session.rsindex 966600a549..ed3eda8832 100644--- a/crates/router/src/core/payments/operations/payment_session.rs+++ b/crates/router/src/core/payments/operations/payment_session.rs@@ -167,6 +167,7 @@ impl<F: Send + Clone, Ctx: PaymentMethodRetrieve>email: None,mandate_id: None,mandate_connector: None,+ customer_acceptance: None,token: None,setup_mandate: None,address: payments::PaymentAddress {diff --git a/crates/router/src/core/payments/operations/payment_start.rs b/crates/router/src/core/payments/operations/payment_start.rsindex 2ca413b73a..650fef7e1b 100644--- a/crates/router/src/core/payments/operations/payment_start.rs+++ b/crates/router/src/core/payments/operations/payment_start.rs@@ -145,6 +145,7 @@ impl<F: Send + Clone, Ctx: PaymentMethodRetrieve>mandate_id: None,mandate_connector: None,setup_mandate: None,+ customer_acceptance: None,token: payment_attempt.payment_token.clone(),address: PaymentAddress {shipping: shipping_address.as_ref().map(|a| a.into()),diff --git a/crates/router/src/core/payments/operations/payment_status.rs b/crates/router/src/core/payments/operations/payment_status.rsindex aa622b3558..70f04ed364 100644--- a/crates/router/src/core/payments/operations/payment_status.rs+++ b/crates/router/src/core/payments/operations/payment_status.rs@@ -414,6 +414,7 @@ async fn get_tracker_for_sync<}),mandate_connector: None,setup_mandate: None,+ customer_acceptance: None,token: None,address: PaymentAddress {shipping: shipping_address.as_ref().map(|a| a.into()),diff --git a/crates/router/src/core/payments/operations/payment_update.rs b/crates/router/src/core/payments/operations/payment_update.rsindex 080667f4b4..81efdbabc4 100644--- a/crates/router/src/core/payments/operations/payment_update.rs+++ b/crates/router/src/core/payments/operations/payment_update.rs@@ -349,7 +349,12 @@ impl<F: Send + Clone, Ctx: PaymentMethodRetrieve>// The operation merges mandate data from both request and payment_attemptlet setup_mandate = setup_mandate.map(Into::into);-+ let mandate_details_present =+ payment_attempt.mandate_details.is_some() || request.mandate_data.is_some();+ helpers::validate_mandate_data_and_future_usage(+ payment_intent.setup_future_usage,+ mandate_details_present,+ )?;let profile_id = payment_intent.profile_id.as_ref()@@ -363,7 +368,7 @@ impl<F: Send + Clone, Ctx: PaymentMethodRetrieve>.to_not_found_response(errors::ApiErrorResponse::BusinessProfileNotFound {id: profile_id.to_string(),})?;-+ let customer_acceptance = request.customer_acceptance.clone().map(From::from);let surcharge_details = request.surcharge_details.map(|request_surcharge_details| {payments::types::SurchargeDetails::from((&request_surcharge_details, &payment_attempt))});@@ -379,6 +384,7 @@ impl<F: Send + Clone, Ctx: PaymentMethodRetrieve>mandate_connector,token,setup_mandate,+ customer_acceptance,address: PaymentAddress {shipping: shipping_address.as_ref().map(|a| a.into()),billing: billing_address.as_ref().map(|a| a.into()),diff --git a/crates/router/src/core/payments/operations/payments_incremental_authorization.rs b/crates/router/src/core/payments/operations/payments_incremental_authorization.rsindex 24292507c0..96cbf9fb9d 100644--- a/crates/router/src/core/payments/operations/payments_incremental_authorization.rs+++ b/crates/router/src/core/payments/operations/payments_incremental_authorization.rs@@ -120,6 +120,7 @@ impl<F: Send + Clone, Ctx: PaymentMethodRetrieve>mandate_id: None,mandate_connector: None,setup_mandate: None,+ customer_acceptance: None,token: None,address: PaymentAddress {billing: None,diff --git a/crates/router/src/core/payments/tokenization.rs b/crates/router/src/core/payments/tokenization.rsindex 1f793e2e18..943550ef43 100644--- a/crates/router/src/core/payments/tokenization.rs+++ b/crates/router/src/core/payments/tokenization.rs@@ -1,6 +1,9 @@use api_models::payment_methods::PaymentMethodsData;use common_enums::PaymentMethod;-use common_utils::{ext_traits::ValueExt, pii};+use common_utils::{+ ext_traits::{Encode, ValueExt},+ pii,+};use error_stack::{report, ResultExt};use masking::ExposeInterface;use router_env::{instrument, tracing};@@ -34,7 +37,6 @@ pub async fn save_payment_method<F: Clone, FData>(merchant_account: &domain::MerchantAccount,payment_method_type: Option<storage_enums::PaymentMethodType>,key_store: &domain::MerchantKeyStore,- is_mandate: bool,) -> RouterResult<Option<String>>whereFData: mandate::MandateBehaviour,@@ -67,16 +69,24 @@ where} else {None};- let future_usage_validation = resp++ let mandate_data_customer_acceptance = resp.request- .get_setup_future_usage()- .map(|future_usage| {- (future_usage == storage_enums::FutureUsage::OffSession && is_mandate)- || (future_usage == storage_enums::FutureUsage::OnSession && !is_mandate)- })- .unwrap_or(false);+ .get_setup_mandate_details()+ .and_then(|mandate_data| mandate_data.customer_acceptance.clone());++ let customer_acceptance = resp+ .request+ .get_customer_acceptance()+ .or(mandate_data_customer_acceptance.clone().map(From::from))+ .map(|ca| ca.encode_to_value())+ .transpose()+ .change_context(errors::ApiErrorResponse::InternalServerError)+ .attach_printable("Unable to serialize customer acceptance to value")?;- let pm_id = if future_usage_validation {+ let pm_id = if resp.request.get_setup_future_usage().is_some()+ && customer_acceptance.is_some()+ {let customer = maybe_customer.to_owned().get_required_value("customer")?;let payment_method_create_request = helpers::get_payment_method_create_request(Some(&resp.request.get_payment_method_data()),@@ -181,6 +191,7 @@ wherelocker_id,merchant_id,pm_metadata,+ customer_acceptance,pm_data_encrypted,key_store,)@@ -243,6 +254,7 @@ where&merchant_account.merchant_id,&customer.customer_id,resp.metadata.clone().map(|val| val.expose()),+ customer_acceptance,locker_id,).await@@ -357,6 +369,7 @@ wherelocker_id,merchant_id,pm_metadata,+ customer_acceptance,pm_data_encrypted,key_store,)diff --git a/crates/router/src/core/payments/transformers.rs b/crates/router/src/core/payments/transformers.rsindex 7c7bac80cf..8ccab155c6 100644--- a/crates/router/src/core/payments/transformers.rs+++ b/crates/router/src/core/payments/transformers.rs@@ -1141,6 +1141,7 @@ impl<F: Clone> TryFrom<PaymentAdditionalData<'_, F>> for types::PaymentsAuthoriz| Some(RequestIncrementalAuthorization::Default)),metadata: additional_data.payment_data.payment_intent.metadata,+ customer_acceptance: payment_data.customer_acceptance,})}}@@ -1436,6 +1437,7 @@ impl<F: Clone> TryFrom<PaymentAdditionalData<'_, F>> for types::SetupMandateRequoff_session: payment_data.mandate_id.as_ref().map(|_| true),mandate_id: payment_data.mandate_id.clone(),setup_mandate_details: payment_data.setup_mandate,+ customer_acceptance: payment_data.customer_acceptance,router_return_url,email: payment_data.email,customer_name,diff --git a/crates/router/src/core/payouts/helpers.rs b/crates/router/src/core/payouts/helpers.rsindex fcd2569ea9..7005e955df 100644--- a/crates/router/src/core/payouts/helpers.rs+++ b/crates/router/src/core/payouts/helpers.rs@@ -382,6 +382,7 @@ pub async fn save_payout_data_to_locker(Some(stored_resp.card_reference),&merchant_account.merchant_id,None,+ None,card_details_encrypted,key_store,)diff --git a/crates/router/src/types.rs b/crates/router/src/types.rsindex 07691879d4..106872fb43 100644--- a/crates/router/src/types.rs+++ b/crates/router/src/types.rs@@ -24,7 +24,7 @@ pub use api_models::{use common_enums::MandateStatus;pub use common_utils::request::{RequestBody, RequestContent};use common_utils::{pii, pii::Email};-use data_models::mandates::MandateData;+use data_models::mandates::{CustomerAcceptance, MandateData};use error_stack::{IntoReport, ResultExt};use masking::Secret;use serde::Serialize;@@ -408,6 +408,7 @@ pub struct PaymentsAuthorizeData {pub setup_future_usage: Option<storage_enums::FutureUsage>,pub mandate_id: Option<api_models::payments::MandateIds>,pub off_session: Option<bool>,+ pub customer_acceptance: Option<CustomerAcceptance>,pub setup_mandate_details: Option<MandateData>,pub browser_info: Option<BrowserInformation>,pub order_details: Option<Vec<api_models::payments::OrderDetailsWithAmount>>,@@ -584,6 +585,7 @@ pub struct SetupMandateRequestData {pub amount: Option<i64>,pub confirm: bool,pub statement_descriptor_suffix: Option<String>,+ pub customer_acceptance: Option<CustomerAcceptance>,pub mandate_id: Option<api_models::payments::MandateIds>,pub setup_future_usage: Option<storage_enums::FutureUsage>,pub off_session: Option<bool>,@@ -1423,6 +1425,7 @@ impl From<&SetupMandateRouterData> for PaymentsAuthorizeData {surcharge_details: None,request_incremental_authorization: data.request.request_incremental_authorization,metadata: None,+ customer_acceptance: data.request.customer_acceptance.clone(),}}}diff --git a/crates/router/src/types/api/verify_connector.rs b/crates/router/src/types/api/verify_connector.rsindex 221d16a8b4..4f3d6f7e29 100644--- a/crates/router/src/types/api/verify_connector.rs+++ b/crates/router/src/types/api/verify_connector.rs@@ -50,6 +50,7 @@ impl VerifyConnectorData {related_transaction_id: None,statement_descriptor_suffix: None,request_incremental_authorization: false,+ customer_acceptance: None,}}diff --git a/crates/router/tests/connectors/aci.rs b/crates/router/tests/connectors/aci.rsindex d3f8147fb2..5c4660805f 100644--- a/crates/router/tests/connectors/aci.rs+++ b/crates/router/tests/connectors/aci.rs@@ -72,6 +72,7 @@ fn construct_payment_router_data() -> types::PaymentsAuthorizeRouterData {surcharge_details: None,request_incremental_authorization: false,metadata: None,+ customer_acceptance: None,},response: Err(types::ErrorResponse::default()),payment_method_id: None,diff --git a/crates/router/tests/connectors/adyen.rs b/crates/router/tests/connectors/adyen.rsindex 12812a7085..55f9f6b4b6 100644--- a/crates/router/tests/connectors/adyen.rs+++ b/crates/router/tests/connectors/adyen.rs@@ -170,6 +170,7 @@ impl AdyenTest {surcharge_details: None,request_incremental_authorization: false,metadata: None,+ customer_acceptance: None,})}}diff --git a/crates/router/tests/connectors/bitpay.rs b/crates/router/tests/connectors/bitpay.rsindex d24e20cd66..93043f37c9 100644--- a/crates/router/tests/connectors/bitpay.rs+++ b/crates/router/tests/connectors/bitpay.rs@@ -96,6 +96,7 @@ fn payment_method_details() -> Option<types::PaymentsAuthorizeData> {surcharge_details: None,request_incremental_authorization: false,metadata: None,+ customer_acceptance: None,})}diff --git a/crates/router/tests/connectors/cashtocode.rs b/crates/router/tests/connectors/cashtocode.rsindex a9d81d2bb6..7dd70d8669 100644--- a/crates/router/tests/connectors/cashtocode.rs+++ b/crates/router/tests/connectors/cashtocode.rs@@ -70,6 +70,7 @@ impl CashtocodeTest {surcharge_details: None,request_incremental_authorization: false,metadata: None,+ customer_acceptance: None,})}diff --git a/crates/router/tests/connectors/coinbase.rs b/crates/router/tests/connectors/coinbase.rsindex 7a872ecb58..b1fffb302c 100644--- a/crates/router/tests/connectors/coinbase.rs+++ b/crates/router/tests/connectors/coinbase.rs@@ -98,6 +98,7 @@ fn payment_method_details() -> Option<types::PaymentsAuthorizeData> {surcharge_details: None,request_incremental_authorization: false,metadata: None,+ customer_acceptance: None,})}diff --git a/crates/router/tests/connectors/cryptopay.rs b/crates/router/tests/connectors/cryptopay.rsindex d61a93c8b8..6eaf514db2 100644--- a/crates/router/tests/connectors/cryptopay.rs+++ b/crates/router/tests/connectors/cryptopay.rs@@ -96,6 +96,7 @@ fn payment_method_details() -> Option<types::PaymentsAuthorizeData> {surcharge_details: None,request_incremental_authorization: false,metadata: None,+ customer_acceptance: None,})}diff --git a/crates/router/tests/connectors/opennode.rs b/crates/router/tests/connectors/opennode.rsindex 8415be949a..4702012597 100644--- a/crates/router/tests/connectors/opennode.rs+++ b/crates/router/tests/connectors/opennode.rs@@ -97,6 +97,7 @@ fn payment_method_details() -> Option<types::PaymentsAuthorizeData> {surcharge_details: None,request_incremental_authorization: false,metadata: None,+ customer_acceptance: None,})}diff --git a/crates/router/tests/connectors/utils.rs b/crates/router/tests/connectors/utils.rsindex 8f749a0b2f..83380f7607 100644--- a/crates/router/tests/connectors/utils.rs+++ b/crates/router/tests/connectors/utils.rs@@ -915,6 +915,7 @@ impl Default for PaymentAuthorizeType {surcharge_details: None,request_incremental_authorization: false,metadata: None,+ customer_acceptance: None,};Self(data)}diff --git a/crates/router/tests/connectors/worldline.rs b/crates/router/tests/connectors/worldline.rsindex c5b12a0b0b..ba946b296b 100644--- a/crates/router/tests/connectors/worldline.rs+++ b/crates/router/tests/connectors/worldline.rs@@ -106,6 +106,7 @@ impl WorldlineTest {surcharge_details: None,request_incremental_authorization: false,metadata: None,+ customer_acceptance: None,})}}diff --git a/openapi/openapi_spec.json b/openapi/openapi_spec.jsonindex ac90185dac..781e121a5b 100644--- a/openapi/openapi_spec.json+++ b/openapi/openapi_spec.json@@ -12724,6 +12724,14 @@],"nullable": true},+ "customer_acceptance": {+ "allOf": [+ {+ "$ref": "#/components/schemas/CustomerAcceptance"+ }+ ],+ "nullable": true+ },"mandate_id": {"type": "string","description": "A unique identifier to link the payment to a mandate. To do Recurring payments after a mandate has been created, pass the mandate_id instead of payment_method_data",@@ -13081,6 +13089,14 @@],"nullable": true},+ "customer_acceptance": {+ "allOf": [+ {+ "$ref": "#/components/schemas/CustomerAcceptance"+ }+ ],+ "nullable": true+ },"mandate_id": {"type": "string","description": "A unique identifier to link the payment to a mandate. To do Recurring payments after a mandate has been created, pass the mandate_id instead of payment_method_data",@@ -13562,6 +13578,14 @@],"nullable": true},+ "customer_acceptance": {+ "allOf": [+ {+ "$ref": "#/components/schemas/CustomerAcceptance"+ }+ ],+ "nullable": true+ },"mandate_id": {"type": "string","description": "A unique identifier to link the payment to a mandate. To do Recurring payments after a mandate has been created, pass the mandate_id instead of payment_method_data",@@ -14572,6 +14596,14 @@],"nullable": true},+ "customer_acceptance": {+ "allOf": [+ {+ "$ref": "#/components/schemas/CustomerAcceptance"+ }+ ],+ "nullable": true+ },"browser_info": {"allOf": [{diff --git a/postman/collection-dir/aci/Flow Testcases/Happy Cases/Scenario11-Create a mandate and recurring payment/Payments - Create/request.json b/postman/collection-dir/aci/Flow Testcases/Happy Cases/Scenario11-Create a mandate and recurring payment/Payments - Create/request.jsonindex f7573b64a6..9988d0e2cb 100644--- a/postman/collection-dir/aci/Flow Testcases/Happy Cases/Scenario11-Create a mandate and recurring payment/Payments - Create/request.json+++ b/postman/collection-dir/aci/Flow Testcases/Happy Cases/Scenario11-Create a mandate and recurring payment/Payments - Create/request.json@@ -59,6 +59,14 @@}}},+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"billing": {"address": {"line1": "1467",diff --git a/postman/collection-dir/aci/Flow Testcases/Happy Cases/Scenario11-Refund recurring payment/Payments - Create/request.json b/postman/collection-dir/aci/Flow Testcases/Happy Cases/Scenario11-Refund recurring payment/Payments - Create/request.jsonindex b66df15088..9570f0f0b8 100644--- a/postman/collection-dir/aci/Flow Testcases/Happy Cases/Scenario11-Refund recurring payment/Payments - Create/request.json+++ b/postman/collection-dir/aci/Flow Testcases/Happy Cases/Scenario11-Refund recurring payment/Payments - Create/request.json@@ -59,6 +59,14 @@}}},+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"shipping": {"address": {"line1": "1467",diff --git a/postman/collection-dir/aci/Flow Testcases/Variation Cases/Scenario9-Create a recurring payment with greater mandate amount/Payments - Create/request.json b/postman/collection-dir/aci/Flow Testcases/Variation Cases/Scenario9-Create a recurring payment with greater mandate amount/Payments - Create/request.jsonindex f7573b64a6..9988d0e2cb 100644--- a/postman/collection-dir/aci/Flow Testcases/Variation Cases/Scenario9-Create a recurring payment with greater mandate amount/Payments - Create/request.json+++ b/postman/collection-dir/aci/Flow Testcases/Variation Cases/Scenario9-Create a recurring payment with greater mandate amount/Payments - Create/request.json@@ -59,6 +59,14 @@}}},+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"billing": {"address": {"line1": "1467",diff --git a/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario10-Create a mandate and recurring payment/Payments - Create/request.json b/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario10-Create a mandate and recurring payment/Payments - Create/request.jsonindex 80dad74bb6..0bf892efdf 100644--- a/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario10-Create a mandate and recurring payment/Payments - Create/request.json+++ b/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario10-Create a mandate and recurring payment/Payments - Create/request.json@@ -60,6 +60,14 @@}}},+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"billing": {"address": {"line1": "1467",diff --git a/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario14-Refund recurring payment/Payments - Create/request.json b/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario14-Refund recurring payment/Payments - Create/request.jsonindex 08e62dca6e..a515beb266 100644--- a/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario14-Refund recurring payment/Payments - Create/request.json+++ b/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario14-Refund recurring payment/Payments - Create/request.json@@ -60,6 +60,14 @@}}},+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"shipping": {"address": {"line1": "1467",diff --git a/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario16-Bank debit-ach/Payments - Create/request.json b/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario16-Bank debit-ach/Payments - Create/request.jsonindex 21c079e0ad..eecdf81074 100644--- a/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario16-Bank debit-ach/Payments - Create/request.json+++ b/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario16-Bank debit-ach/Payments - Create/request.json@@ -32,6 +32,14 @@"authentication_type": "three_ds","return_url": "https://duck.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"billing": {"address": {"line1": "1467",diff --git a/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario17-Bank debit-Bacs/Payments - Create/request.json b/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario17-Bank debit-Bacs/Payments - Create/request.jsonindex 1ec9a829a4..660ef06c51 100644--- a/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario17-Bank debit-Bacs/Payments - Create/request.json+++ b/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario17-Bank debit-Bacs/Payments - Create/request.json@@ -32,6 +32,14 @@"authentication_type": "no_three_ds","return_url": "https://duck.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"billing": {"address": {"line1": "1467",diff --git a/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario19-Add card flow/Payments - Create/request.json b/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario19-Add card flow/Payments - Create/request.jsonindex 9260edb1a9..397f164511 100644--- a/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario19-Add card flow/Payments - Create/request.json+++ b/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario19-Add card flow/Payments - Create/request.json@@ -33,6 +33,14 @@"authentication_type": "no_three_ds","return_url": "https://google.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"payment_method": "card","payment_method_type": "credit","payment_method_data": {@@ -89,12 +97,8 @@},"url": {"raw": "{{baseUrl}}/payments",- "host": [- "{{baseUrl}}"- ],- "path": [- "payments"- ]+ "host": ["{{baseUrl}}"],+ "path": ["payments"]},"description": "To process a payment you will have to create a payment, attach a payment method and confirm. Depending on the user journey you wish to achieve, you may opt to all the steps in a single request or in a sequence of API request using following APIs: (i) Payments - Update, (ii) Payments - Confirm, and (iii) Payments - Capture"}diff --git a/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario20-Pass Invalid CVV for save card flow and verify failed payment/Payments - Create/request.json b/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario20-Pass Invalid CVV for save card flow and verify failed payment/Payments - Create/request.jsonindex 9260edb1a9..397f164511 100644--- a/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario20-Pass Invalid CVV for save card flow and verify failed payment/Payments - Create/request.json+++ b/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario20-Pass Invalid CVV for save card flow and verify failed payment/Payments - Create/request.json@@ -33,6 +33,14 @@"authentication_type": "no_three_ds","return_url": "https://google.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"payment_method": "card","payment_method_type": "credit","payment_method_data": {@@ -89,12 +97,8 @@},"url": {"raw": "{{baseUrl}}/payments",- "host": [- "{{baseUrl}}"- ],- "path": [- "payments"- ]+ "host": ["{{baseUrl}}"],+ "path": ["payments"]},"description": "To process a payment you will have to create a payment, attach a payment method and confirm. Depending on the user journey you wish to achieve, you may opt to all the steps in a single request or in a sequence of API request using following APIs: (i) Payments - Update, (ii) Payments - Confirm, and (iii) Payments - Capture"}diff --git a/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario21-Don't Pass CVV for save card flow and verify failed payment Copy/Payments - Create/request.json b/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario21-Don't Pass CVV for save card flow and verify failed payment Copy/Payments - Create/request.jsonindex 9260edb1a9..397f164511 100644--- a/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario21-Don't Pass CVV for save card flow and verify failed payment Copy/Payments - Create/request.json+++ b/postman/collection-dir/adyen_uk/Flow Testcases/Happy Cases/Scenario21-Don't Pass CVV for save card flow and verify failed payment Copy/Payments - Create/request.json@@ -33,6 +33,14 @@"authentication_type": "no_three_ds","return_url": "https://google.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"payment_method": "card","payment_method_type": "credit","payment_method_data": {@@ -89,12 +97,8 @@},"url": {"raw": "{{baseUrl}}/payments",- "host": [- "{{baseUrl}}"- ],- "path": [- "payments"- ]+ "host": ["{{baseUrl}}"],+ "path": ["payments"]},"description": "To process a payment you will have to create a payment, attach a payment method and confirm. Depending on the user journey you wish to achieve, you may opt to all the steps in a single request or in a sequence of API request using following APIs: (i) Payments - Update, (ii) Payments - Confirm, and (iii) Payments - Capture"}diff --git a/postman/collection-dir/adyen_uk/Flow Testcases/Variation Cases/Scenario9-Create a recurring payment with greater mandate amount/Payments - Create/request.json b/postman/collection-dir/adyen_uk/Flow Testcases/Variation Cases/Scenario9-Create a recurring payment with greater mandate amount/Payments - Create/request.jsonindex 93e802128f..40a78911a9 100644--- a/postman/collection-dir/adyen_uk/Flow Testcases/Variation Cases/Scenario9-Create a recurring payment with greater mandate amount/Payments - Create/request.json+++ b/postman/collection-dir/adyen_uk/Flow Testcases/Variation Cases/Scenario9-Create a recurring payment with greater mandate amount/Payments - Create/request.json@@ -59,6 +59,14 @@}}},+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"billing": {"address": {"line1": "1467",diff --git a/postman/collection-dir/authorizedotnet/Flow Testcases/Variation Cases/Scenario11-Create a recurring payment with greater mandate amount/Payments - Create/request.json b/postman/collection-dir/authorizedotnet/Flow Testcases/Variation Cases/Scenario11-Create a recurring payment with greater mandate amount/Payments - Create/request.jsonindex e3d19912b7..d152474c37 100644--- a/postman/collection-dir/authorizedotnet/Flow Testcases/Variation Cases/Scenario11-Create a recurring payment with greater mandate amount/Payments - Create/request.json+++ b/postman/collection-dir/authorizedotnet/Flow Testcases/Variation Cases/Scenario11-Create a recurring payment with greater mandate amount/Payments - Create/request.json@@ -59,6 +59,14 @@}}},+ "customer_acceptance": {+ "acceptance_type": "online",+ "accepted_at": "2022-09-10T10:11:12Z",+ "online": {+ "ip_address": "123.32.25.123",+ "user_agent": "Mozilla/5.0 (Linux; Android 12; SM-S906N Build/QP1A.190711.020; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/80.0.3987.119 Mobile Safari/537.36"+ }+ },"billing": {"address": {"line1": "1467",diff --git a/postman/collection-dir/bankofamerica/Flow Testcases/Happy Cases/Scenario1-Create payment with confirm true/Payments - Create/request.json b/postman/collection-dir/bankofamerica/Flow Testcases/Happy Cases/Scenario1-Create payment with confirm true/Payments - Create/request.jsonindex e37391b78b..43eb0c9cc1 100644--- a/postman/collection-dir/bankofamerica/Flow Testcases/Happy Cases/Scenario1-Create payment with confirm true/Payments - Create/request.json+++ b/postman/collection-dir/bankofamerica/Flow Testcases/Happy Cases/Scenario1-Create payment with confirm true/Payments - Create/request.json@@ -35,6 +35,14 @@"authentication_type": "no_three_ds","return_url": "https://duck.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "online",+ "accepted_at": "2022-09-10T10:11:12Z",+ "online": {+ "ip_address": "123.32.25.123",+ "user_agent": "Mozilla/5.0 (Linux; Android 12; SM-S906N Build/QP1A.190711.020; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/80.0.3987.119 Mobile Safari/537.36"+ }+ },"payment_method": "card","payment_method_type": "debit","payment_method_data": {@@ -87,12 +95,8 @@},"url": {"raw": "{{baseUrl}}/payments",- "host": [- "{{baseUrl}}"- ],- "path": [- "payments"- ]+ "host": ["{{baseUrl}}"],+ "path": ["payments"]},"description": "To process a payment you will have to create a payment, attach a payment method and confirm. Depending on the user journey you wish to achieve, you may opt to all the steps in a single request or in a sequence of API request using following APIs: (i) Payments - Update, (ii) Payments - Confirm, and (iii) Payments - Capture"}diff --git a/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario12-Add card flow/Payments - Create/request.json b/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario12-Add card flow/Payments - Create/request.jsonindex 056b9269a2..d0320b0997 100644--- a/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario12-Add card flow/Payments - Create/request.json+++ b/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario12-Add card flow/Payments - Create/request.json@@ -33,6 +33,14 @@"authentication_type": "no_three_ds","return_url": "https://duck.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "online",+ "accepted_at": "2022-09-10T10:11:12Z",+ "online": {+ "ip_address": "123.32.25.123",+ "user_agent": "Mozilla/5.0 (Linux; Android 12; SM-S906N Build/QP1A.190711.020; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/80.0.3987.119 Mobile Safari/537.36"+ }+ },"payment_method": "card","payment_method_type": "credit","payment_method_data": {diff --git a/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario13-Don't Pass CVV for save card flow and verify success payment/Payments - Create/request.json b/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario13-Don't Pass CVV for save card flow and verify success payment/Payments - Create/request.jsonindex 1d85fee735..fe4adccda4 100644--- a/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario13-Don't Pass CVV for save card flow and verify success payment/Payments - Create/request.json+++ b/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario13-Don't Pass CVV for save card flow and verify success payment/Payments - Create/request.json@@ -33,6 +33,14 @@"authentication_type": "no_three_ds","return_url": "https://duck.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "online",+ "accepted_at": "2022-09-10T10:11:12Z",+ "online": {+ "ip_address": "123.32.25.123",+ "user_agent": "Mozilla/5.0 (Linux; Android 12; SM-S906N Build/QP1A.190711.020; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/80.0.3987.119 Mobile Safari/537.36"+ }+ },"payment_method": "card","payment_method_type": "credit","payment_method_data": {diff --git a/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario14-Save card payment with manual capture/Payments - Create/request.json b/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario14-Save card payment with manual capture/Payments - Create/request.jsonindex 73457bf319..aaa993e4ee 100644--- a/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario14-Save card payment with manual capture/Payments - Create/request.json+++ b/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario14-Save card payment with manual capture/Payments - Create/request.json@@ -33,6 +33,14 @@"authentication_type": "no_three_ds","return_url": "https://duck.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "online",+ "accepted_at": "2022-09-10T10:11:12Z",+ "online": {+ "ip_address": "123.32.25.123",+ "user_agent": "Mozilla/5.0 (Linux; Android 12; SM-S906N Build/QP1A.190711.020; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/80.0.3987.119 Mobile Safari/537.36"+ }+ },"payment_method": "card","payment_method_type": "credit","payment_method_data": {diff --git a/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario15-Create payment without customer_id and with billing address and shipping address/Payments - Create/request.json b/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario15-Create payment without customer_id and with billing address and shipping address/Payments - Create/request.jsonindex ffda1aef2d..050f353af5 100644--- a/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario15-Create payment without customer_id and with billing address and shipping address/Payments - Create/request.json+++ b/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario15-Create payment without customer_id and with billing address and shipping address/Payments - Create/request.json@@ -35,6 +35,14 @@"authentication_type": "no_three_ds","return_url": "https://duck.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "online",+ "accepted_at": "2022-09-10T10:11:12Z",+ "online": {+ "ip_address": "123.32.25.123",+ "user_agent": "Mozilla/5.0 (Linux; Android 12; SM-S906N Build/QP1A.190711.020; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/80.0.3987.119 Mobile Safari/537.36"+ }+ },"payment_method": "card","payment_method_type": "debit","payment_method_data": {diff --git a/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario8-Create a failure card payment with confirm true/Payments - Create/request.json b/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario8-Create a failure card payment with confirm true/Payments - Create/request.jsonindex 97cce7936c..63d1eeba23 100644--- a/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario8-Create a failure card payment with confirm true/Payments - Create/request.json+++ b/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario8-Create a failure card payment with confirm true/Payments - Create/request.json@@ -35,6 +35,14 @@"authentication_type": "no_three_ds","return_url": "https://duck.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "online",+ "accepted_at": "2022-09-10T10:11:12Z",+ "online": {+ "ip_address": "123.32.25.123",+ "user_agent": "Mozilla/5.0 (Linux; Android 12; SM-S906N Build/QP1A.190711.020; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/80.0.3987.119 Mobile Safari/537.36"+ }+ },"payment_method": "card","payment_method_type": "debit","payment_method_data": {diff --git a/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario9-Update amount with automatic capture/Payments - Confirm/request.json b/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario9-Update amount with automatic capture/Payments - Confirm/request.jsonindex 9699acd8bb..962144d6bc 100644--- a/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario9-Update amount with automatic capture/Payments - Confirm/request.json+++ b/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario9-Update amount with automatic capture/Payments - Confirm/request.json@@ -57,6 +57,14 @@}},"setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "online",+ "accepted_at": "2022-09-10T10:11:12Z",+ "online": {+ "ip_address": "123.32.25.123",+ "user_agent": "Mozilla/5.0 (Linux; Android 12; SM-S906N Build/QP1A.190711.020; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/80.0.3987.119 Mobile Safari/537.36"+ }+ },"browser_info": {"user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.110 Safari/537.36","accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8",diff --git a/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario9a-Update amount with manual capture/Payments - Confirm/request.json b/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario9a-Update amount with manual capture/Payments - Confirm/request.jsonindex 9699acd8bb..962144d6bc 100644--- a/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario9a-Update amount with manual capture/Payments - Confirm/request.json+++ b/postman/collection-dir/nmi/Flow Testcases/Happy Cases/Scenario9a-Update amount with manual capture/Payments - Confirm/request.json@@ -57,6 +57,14 @@}},"setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "online",+ "accepted_at": "2022-09-10T10:11:12Z",+ "online": {+ "ip_address": "123.32.25.123",+ "user_agent": "Mozilla/5.0 (Linux; Android 12; SM-S906N Build/QP1A.190711.020; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/80.0.3987.119 Mobile Safari/537.36"+ }+ },"browser_info": {"user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.110 Safari/537.36","accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8",diff --git a/postman/collection-dir/nmi/Flow Testcases/Variation Cases/Scenario9-Create a recurring payment with greater mandate amount Copy/Payments - Create/request.json b/postman/collection-dir/nmi/Flow Testcases/Variation Cases/Scenario9-Create a recurring payment with greater mandate amount Copy/Payments - Create/request.jsonindex 7aeaf601cc..2cbfe4a20f 100644--- a/postman/collection-dir/nmi/Flow Testcases/Variation Cases/Scenario9-Create a recurring payment with greater mandate amount Copy/Payments - Create/request.json+++ b/postman/collection-dir/nmi/Flow Testcases/Variation Cases/Scenario9-Create a recurring payment with greater mandate amount Copy/Payments - Create/request.json@@ -59,6 +59,14 @@}}},+ "customer_acceptance": {+ "acceptance_type": "online",+ "accepted_at": "2022-09-10T10:11:12Z",+ "online": {+ "ip_address": "123.32.25.123",+ "user_agent": "Mozilla/5.0 (Linux; Android 12; SM-S906N Build/QP1A.190711.020; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/80.0.3987.119 Mobile Safari/537.36"+ }+ },"billing": {"address": {"line1": "1467",diff --git a/postman/collection-dir/paypal/Flow Testcases/Happy Cases/Scenario6-Create Wallet - Paypal/Payments - Create/request.json b/postman/collection-dir/paypal/Flow Testcases/Happy Cases/Scenario6-Create Wallet - Paypal/Payments - Create/request.jsonindex 824bfb4923..7201fa121b 100644--- a/postman/collection-dir/paypal/Flow Testcases/Happy Cases/Scenario6-Create Wallet - Paypal/Payments - Create/request.json+++ b/postman/collection-dir/paypal/Flow Testcases/Happy Cases/Scenario6-Create Wallet - Paypal/Payments - Create/request.json@@ -33,6 +33,14 @@"authentication_type": "three_ds","return_url": "https://duck.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "online",+ "accepted_at": "2022-09-10T10:11:12Z",+ "online": {+ "ip_address": "123.32.25.123",+ "user_agent": "Mozilla/5.0 (Linux; Android 12; SM-S906N Build/QP1A.190711.020; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/80.0.3987.119 Mobile Safari/537.36"+ }+ },"billing": {"address": {"line1": "1467",diff --git a/postman/collection-dir/paypal/Flow Testcases/Happy Cases/Scenario7-Create Wallet - Paypal with confrm false/Payments - Confirm/request.json b/postman/collection-dir/paypal/Flow Testcases/Happy Cases/Scenario7-Create Wallet - Paypal with confrm false/Payments - Confirm/request.jsonindex efa17534b1..f5da408b2f 100644--- a/postman/collection-dir/paypal/Flow Testcases/Happy Cases/Scenario7-Create Wallet - Paypal with confrm false/Payments - Confirm/request.json+++ b/postman/collection-dir/paypal/Flow Testcases/Happy Cases/Scenario7-Create Wallet - Paypal with confrm false/Payments - Confirm/request.json@@ -45,6 +45,14 @@"wallet": {"paypal_redirect": {}}+ },+ "customer_acceptance": {+ "acceptance_type": "online",+ "accepted_at": "2022-09-10T10:11:12Z",+ "online": {+ "ip_address": "123.32.25.123",+ "user_agent": "Mozilla/5.0 (Linux; Android 12; SM-S906N Build/QP1A.190711.020; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/80.0.3987.119 Mobile Safari/537.36"+ }}}},diff --git a/postman/collection-dir/shift4/Flow Testcases/Variation Cases/Scenario9-Create a recurring payment with greater mandate amount/Payments - Create/request.json b/postman/collection-dir/shift4/Flow Testcases/Variation Cases/Scenario9-Create a recurring payment with greater mandate amount/Payments - Create/request.jsonindex 57d625e7c3..fbbd60339e 100644--- a/postman/collection-dir/shift4/Flow Testcases/Variation Cases/Scenario9-Create a recurring payment with greater mandate amount/Payments - Create/request.json+++ b/postman/collection-dir/shift4/Flow Testcases/Variation Cases/Scenario9-Create a recurring payment with greater mandate amount/Payments - Create/request.json@@ -59,6 +59,14 @@}}},+ "customer_acceptance": {+ "acceptance_type": "online",+ "accepted_at": "2022-09-10T10:11:12Z",+ "online": {+ "ip_address": "123.32.25.123",+ "user_agent": "Mozilla/5.0 (Linux; Android 12; SM-S906N Build/QP1A.190711.020; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/80.0.3987.119 Mobile Safari/537.36"+ }+ },"billing": {"address": {"line1": "1467",diff --git a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario1-Create payment with confirm true/Payments - Create/request.json b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario1-Create payment with confirm true/Payments - Create/request.jsonindex 93bcc23194..9d0fac32c1 100644--- a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario1-Create payment with confirm true/Payments - Create/request.json+++ b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario1-Create payment with confirm true/Payments - Create/request.json@@ -35,6 +35,14 @@"authentication_type": "no_three_ds","return_url": "https://duck.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "online",+ "accepted_at": "2022-09-10T10:11:12Z",+ "online": {+ "ip_address": "123.32.25.123",+ "user_agent": "Mozilla/5.0 (Linux; Android 12; SM-S906N Build/QP1A.190711.020; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/80.0.3987.119 Mobile Safari/537.36"+ }+ },"payment_method": "card","payment_method_type": "debit","payment_method_data": {diff --git a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario10-Create a mandate and recurring payment/Payments - Create/request.json b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario10-Create a mandate and recurring payment/Payments - Create/request.jsonindex 3ffbe03a60..b5ef6b1afe 100644--- a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario10-Create a mandate and recurring payment/Payments - Create/request.json+++ b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario10-Create a mandate and recurring payment/Payments - Create/request.json@@ -59,6 +59,14 @@}}},+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"billing": {"address": {"line1": "1467",@@ -98,12 +106,8 @@},"url": {"raw": "{{baseUrl}}/payments",- "host": [- "{{baseUrl}}"- ],- "path": [- "payments"- ]+ "host": ["{{baseUrl}}"],+ "path": ["payments"]},"description": "To process a payment you will have to create a payment, attach a payment method and confirm. Depending on the user journey you wish to achieve, you may opt to all the steps in a single request or in a sequence of API request using following APIs: (i) Payments - Update, (ii) Payments - Confirm, and (iii) Payments - Capture"}diff --git a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario11-Refund recurring payment/Payments - Create/request.json b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario11-Refund recurring payment/Payments - Create/request.jsonindex 9df18b5e88..61f007ede6 100644--- a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario11-Refund recurring payment/Payments - Create/request.json+++ b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario11-Refund recurring payment/Payments - Create/request.json@@ -59,6 +59,14 @@}}},+ "customer_acceptance": {+ "acceptance_type": "online",+ "accepted_at": "2022-09-10T10:11:12Z",+ "online": {+ "ip_address": "123.32.25.123",+ "user_agent": "Mozilla/5.0 (Linux; Android 12; SM-S906N Build/QP1A.190711.020; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/80.0.3987.119 Mobile Safari/537.36"+ }+ },"shipping": {"address": {"line1": "1467",@@ -86,12 +94,8 @@},"url": {"raw": "{{baseUrl}}/payments",- "host": [- "{{baseUrl}}"- ],- "path": [- "payments"- ]+ "host": ["{{baseUrl}}"],+ "path": ["payments"]},"description": "To process a payment you will have to create a payment, attach a payment method and confirm. Depending on the user journey you wish to achieve, you may opt to all the steps in a single request or in a sequence of API request using following APIs: (i) Payments - Update, (ii) Payments - Confirm, and (iii) Payments - Capture"}diff --git a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario20-Bank Debit-ach/Payments - Create/request.json b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario20-Bank Debit-ach/Payments - Create/request.jsonindex eda0801c9c..78d949505f 100644--- a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario20-Bank Debit-ach/Payments - Create/request.json+++ b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario20-Bank Debit-ach/Payments - Create/request.json@@ -23,9 +23,7 @@"confirm": true,"business_label": "default","capture_method": "automatic",- "connector": [- "stripe"- ],+ "connector": ["stripe"],"customer_id": "klarna","capture_on": "2022-09-10T10:11:12Z","authentication_type": "three_ds",@@ -55,6 +53,14 @@}}},+ "customer_acceptance": {+ "acceptance_type": "online",+ "accepted_at": "2022-09-10T10:11:12Z",+ "online": {+ "ip_address": "123.32.25.123",+ "user_agent": "Mozilla/5.0 (Linux; Android 12; SM-S906N Build/QP1A.190711.020; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/80.0.3987.119 Mobile Safari/537.36"+ }+ },"payment_method": "bank_debit","payment_method_type": "ach","payment_method_data": {@@ -85,12 +91,8 @@},"url": {"raw": "{{baseUrl}}/payments",- "host": [- "{{baseUrl}}"- ],- "path": [- "payments"- ]+ "host": ["{{baseUrl}}"],+ "path": ["payments"]},"description": "To process a payment you will have to create a payment, attach a payment method and confirm. Depending on the user journey you wish to achieve, you may opt to all the steps in a single request or in a sequence of API request using following APIs: (i) Payments - Update, (ii) Payments - Confirm, and (iii) Payments - Capture"}diff --git a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario22- Update address and List Payment method/Payments - Confirm/request.json b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario22- Update address and List Payment method/Payments - Confirm/request.jsonindex 20b99223ac..43515f184b 100644--- a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario22- Update address and List Payment method/Payments - Confirm/request.json+++ b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario22- Update address and List Payment method/Payments - Confirm/request.json@@ -52,6 +52,7 @@}}},+ "setup_future_usage": "off_session","mandate_data": {"customer_acceptance": {"acceptance_type": "offline",@@ -73,7 +74,14 @@}}},- "setup_future_usage": "off_session",+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"browser_info": {"user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.110 Safari/537.36","accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8",@@ -90,14 +98,8 @@},"url": {"raw": "{{baseUrl}}/payments/:id/confirm",- "host": [- "{{baseUrl}}"- ],- "path": [- "payments",- ":id",- "confirm"- ],+ "host": ["{{baseUrl}}"],+ "path": ["payments", ":id", "confirm"],"variable": [{"key": "id",diff --git a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario22- Update address and List Payment method/Payments - Create/request.json b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario22- Update address and List Payment method/Payments - Create/request.jsonindex 785122a83c..beeb5b3983 100644--- a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario22- Update address and List Payment method/Payments - Create/request.json+++ b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario22- Update address and List Payment method/Payments - Create/request.json@@ -71,12 +71,8 @@},"url": {"raw": "{{baseUrl}}/payments",- "host": [- "{{baseUrl}}"- ],- "path": [- "payments"- ]+ "host": ["{{baseUrl}}"],+ "path": ["payments"]},"description": "To process a payment you will have to create a payment, attach a payment method and confirm. Depending on the user journey you wish to achieve, you may opt to all the steps in a single request or in a sequence of API request using following APIs: (i) Payments - Update, (ii) Payments - Confirm, and (iii) Payments - Capture"}diff --git a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario23- Update Amount/Payments - Confirm/request.json b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario23- Update Amount/Payments - Confirm/request.jsonindex 2b86201e2f..1b1757b9a4 100644--- a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario23- Update Amount/Payments - Confirm/request.json+++ b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario23- Update Amount/Payments - Confirm/request.json@@ -57,6 +57,14 @@}},"setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"browser_info": {"user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.110 Safari/537.36","accept_header": "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8",diff --git a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario24-Add card flow/Payments - Create/request.json b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario24-Add card flow/Payments - Create/request.jsonindex 2019bae879..2ac0cacfb9 100644--- a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario24-Add card flow/Payments - Create/request.json+++ b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario24-Add card flow/Payments - Create/request.json@@ -33,6 +33,14 @@"authentication_type": "no_three_ds","return_url": "https://google.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"payment_method": "card","payment_method_type": "credit","payment_method_data": {@@ -93,12 +101,8 @@},"url": {"raw": "{{baseUrl}}/payments",- "host": [- "{{baseUrl}}"- ],- "path": [- "payments"- ]+ "host": ["{{baseUrl}}"],+ "path": ["payments"]},"description": "To process a payment you will have to create a payment, attach a payment method and confirm. Depending on the user journey you wish to achieve, you may opt to all the steps in a single request or in a sequence of API request using following APIs: (i) Payments - Update, (ii) Payments - Confirm, and (iii) Payments - Capture"}diff --git a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario25-Don't Pass CVV for save card flow and verifysuccess payment/Payments - Create/request.json b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario25-Don't Pass CVV for save card flow and verifysuccess payment/Payments - Create/request.jsonindex 4f02f7b680..150106cfde 100644--- a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario25-Don't Pass CVV for save card flow and verifysuccess payment/Payments - Create/request.json+++ b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario25-Don't Pass CVV for save card flow and verifysuccess payment/Payments - Create/request.json@@ -33,6 +33,14 @@"authentication_type": "no_three_ds","return_url": "https://google.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"payment_method": "card","payment_method_type": "credit","payment_method_data": {@@ -93,12 +101,8 @@},"url": {"raw": "{{baseUrl}}/payments",- "host": [- "{{baseUrl}}"- ],- "path": [- "payments"- ]+ "host": ["{{baseUrl}}"],+ "path": ["payments"]},"description": "To process a payment you will have to create a payment, attach a payment method and confirm. Depending on the user journey you wish to achieve, you may opt to all the steps in a single request or in a sequence of API request using following APIs: (i) Payments - Update, (ii) Payments - Confirm, and (iii) Payments - Capture"}diff --git a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario26-Save card payment with manual capture/Payments - Create/request.json b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario26-Save card payment with manual capture/Payments - Create/request.jsonindex 988bc4b800..d73166871c 100644--- a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario26-Save card payment with manual capture/Payments - Create/request.json+++ b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario26-Save card payment with manual capture/Payments - Create/request.json@@ -33,6 +33,14 @@"authentication_type": "no_three_ds","return_url": "https://google.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"payment_method": "card","payment_method_type": "credit","payment_method_data": {@@ -93,12 +101,8 @@},"url": {"raw": "{{baseUrl}}/payments",- "host": [- "{{baseUrl}}"- ],- "path": [- "payments"- ]+ "host": ["{{baseUrl}}"],+ "path": ["payments"]},"description": "To process a payment you will have to create a payment, attach a payment method and confirm. Depending on the user journey you wish to achieve, you may opt to all the steps in a single request or in a sequence of API request using following APIs: (i) Payments - Update, (ii) Payments - Confirm, and (iii) Payments - Capture"}diff --git a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario27-Create payment without customer_id and with billing address and shipping address/Payments - Create/request.json b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario27-Create payment without customer_id and with billing address and shipping address/Payments - Create/request.jsonindex 60e56bb581..6a9836d232 100644--- a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario27-Create payment without customer_id and with billing address and shipping address/Payments - Create/request.json+++ b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario27-Create payment without customer_id and with billing address and shipping address/Payments - Create/request.json@@ -35,6 +35,14 @@"authentication_type": "no_three_ds","return_url": "https://duck.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"payment_method": "card","payment_method_type": "debit","payment_method_data": {@@ -87,12 +95,8 @@},"url": {"raw": "{{baseUrl}}/payments",- "host": [- "{{baseUrl}}"- ],- "path": [- "payments"- ]+ "host": ["{{baseUrl}}"],+ "path": ["payments"]},"description": "To process a payment you will have to create a payment, attach a payment method and confirm. Depending on the user journey you wish to achieve, you may opt to all the steps in a single request or in a sequence of API request using following APIs: (i) Payments - Update, (ii) Payments - Confirm, and (iii) Payments - Capture"}diff --git a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario28-Confirm a payment with requires_customer_action status/Payments - Create with confirm true/request.json b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario28-Confirm a payment with requires_customer_action status/Payments - Create with confirm true/request.jsonindex d14ae6582c..7e28058ccf 100644--- a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario28-Confirm a payment with requires_customer_action status/Payments - Create with confirm true/request.json+++ b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario28-Confirm a payment with requires_customer_action status/Payments - Create with confirm true/request.json@@ -35,6 +35,14 @@"authentication_type": "three_ds","return_url": "https://duck.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"payment_method": "card","payment_method_data": {"card": {diff --git a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario6-Create 3DS payment/Payments - Create/request.json b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario6-Create 3DS payment/Payments - Create/request.jsonindex d14ae6582c..7e28058ccf 100644--- a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario6-Create 3DS payment/Payments - Create/request.json+++ b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario6-Create 3DS payment/Payments - Create/request.json@@ -35,6 +35,14 @@"authentication_type": "three_ds","return_url": "https://duck.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"payment_method": "card","payment_method_data": {"card": {diff --git a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario8-Create a failure card payment with confirm true/Payments - Create/request.json b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario8-Create a failure card payment with confirm true/Payments - Create/request.jsonindex 6d1bc5e0a0..a3e0f52b8d 100644--- a/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario8-Create a failure card payment with confirm true/Payments - Create/request.json+++ b/postman/collection-dir/stripe/Flow Testcases/Happy Cases/Scenario8-Create a failure card payment with confirm true/Payments - Create/request.json@@ -35,6 +35,14 @@"authentication_type": "no_three_ds","return_url": "https://duck.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"payment_method": "card","payment_method_type": "debit","payment_method_data": {@@ -87,12 +95,8 @@},"url": {"raw": "{{baseUrl}}/payments",- "host": [- "{{baseUrl}}"- ],- "path": [- "payments"- ]+ "host": ["{{baseUrl}}"],+ "path": ["payments"]},"description": "To process a payment you will have to create a payment, attach a payment method and confirm. Depending on the user journey you wish to achieve, you may opt to all the steps in a single request or in a sequence of API request using following APIs: (i) Payments - Update, (ii) Payments - Confirm, and (iii) Payments - Capture"}diff --git a/postman/collection-dir/stripe/Flow Testcases/Variation Cases/Scenario9-Create a recurring payment with greater mandate amount/Payments - Create/request.json b/postman/collection-dir/stripe/Flow Testcases/Variation Cases/Scenario9-Create a recurring payment with greater mandate amount/Payments - Create/request.jsonindex a5c9391cf7..b5ef6b1afe 100644--- a/postman/collection-dir/stripe/Flow Testcases/Variation Cases/Scenario9-Create a recurring payment with greater mandate amount/Payments - Create/request.json+++ b/postman/collection-dir/stripe/Flow Testcases/Variation Cases/Scenario9-Create a recurring payment with greater mandate amount/Payments - Create/request.json@@ -59,6 +59,14 @@}}},+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"billing": {"address": {"line1": "1467",diff --git a/postman/collection-dir/stripe/PaymentMethods/Payments - Create/request.json b/postman/collection-dir/stripe/PaymentMethods/Payments - Create/request.jsonindex ac22dac750..cc330f3c8f 100644--- a/postman/collection-dir/stripe/PaymentMethods/Payments - Create/request.json+++ b/postman/collection-dir/stripe/PaymentMethods/Payments - Create/request.json@@ -33,6 +33,14 @@"authentication_type": "no_three_ds","return_url": "https://duck.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"payment_method": "card","payment_method_type": "debit","payment_method_data": {diff --git a/postman/collection-dir/zen/Flow Testcases/Happy Cases/Scenario1-Create payment with confirm true/Payments - Create/request.json b/postman/collection-dir/zen/Flow Testcases/Happy Cases/Scenario1-Create payment with confirm true/Payments - Create/request.jsonindex 7afc6d61c4..fd84bcaadb 100644--- a/postman/collection-dir/zen/Flow Testcases/Happy Cases/Scenario1-Create payment with confirm true/Payments - Create/request.json+++ b/postman/collection-dir/zen/Flow Testcases/Happy Cases/Scenario1-Create payment with confirm true/Payments - Create/request.json@@ -32,6 +32,14 @@"authentication_type": "no_three_ds","return_url": "https://duck.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"billing": {"address": {"line1": "1467",diff --git a/postman/collection-dir/zen/Flow Testcases/Happy Cases/Scenario2-Create payment with confirm false/Payments - Confirm/request.json b/postman/collection-dir/zen/Flow Testcases/Happy Cases/Scenario2-Create payment with confirm false/Payments - Confirm/request.jsonindex 778f887268..2f295eba3a 100644--- a/postman/collection-dir/zen/Flow Testcases/Happy Cases/Scenario2-Create payment with confirm false/Payments - Confirm/request.json+++ b/postman/collection-dir/zen/Flow Testcases/Happy Cases/Scenario2-Create payment with confirm false/Payments - Confirm/request.json@@ -51,6 +51,14 @@"java_script_enabled": true,"ip_address": "127.0.0.1"},+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"order_details": [{"amount": 6540,@@ -60,6 +68,7 @@]}},+"url": {"raw": "{{baseUrl}}/payments/:id/confirm","host": ["{{baseUrl}}"],diff --git a/postman/collection-dir/zen/Flow Testcases/Happy Cases/Scenario3-Create payment without PMD/Payments - Create/request.json b/postman/collection-dir/zen/Flow Testcases/Happy Cases/Scenario3-Create payment without PMD/Payments - Create/request.jsonindex a6aef6ecb7..042a4bc1f7 100644--- a/postman/collection-dir/zen/Flow Testcases/Happy Cases/Scenario3-Create payment without PMD/Payments - Create/request.json+++ b/postman/collection-dir/zen/Flow Testcases/Happy Cases/Scenario3-Create payment without PMD/Payments - Create/request.json@@ -32,6 +32,14 @@"authentication_type": "no_three_ds","return_url": "https://duck.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"billing": {"address": {"line1": "1467",diff --git a/postman/collection-dir/zen/Flow Testcases/Happy Cases/Scenario4-Create 3DS payment/Payments - Create/request.json b/postman/collection-dir/zen/Flow Testcases/Happy Cases/Scenario4-Create 3DS payment/Payments - Create/request.jsonindex ee35432532..bed15211ee 100644--- a/postman/collection-dir/zen/Flow Testcases/Happy Cases/Scenario4-Create 3DS payment/Payments - Create/request.json+++ b/postman/collection-dir/zen/Flow Testcases/Happy Cases/Scenario4-Create 3DS payment/Payments - Create/request.json@@ -32,6 +32,14 @@"authentication_type": "no_three_ds","return_url": "https://duck.com","setup_future_usage": "off_session",+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"order_details": [{"amount": 6540,diff --git a/postman/collection-dir/zen/Flow Testcases/Happy Cases/Scenario5-Create 3DS payment with confrm false/Payments - Create/request.json b/postman/collection-dir/zen/Flow Testcases/Happy Cases/Scenario5-Create 3DS payment with confrm false/Payments - Create/request.jsonindex 01fa401365..91a932b12d 100644--- a/postman/collection-dir/zen/Flow Testcases/Happy Cases/Scenario5-Create 3DS payment with confrm false/Payments - Create/request.json+++ b/postman/collection-dir/zen/Flow Testcases/Happy Cases/Scenario5-Create 3DS payment with confrm false/Payments - Create/request.json@@ -32,6 +32,14 @@"authentication_type": "no_three_ds","return_url": "https://duck.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"billing": {"address": {"line1": "1467",diff --git a/postman/collection-dir/zen/Flow Testcases/QuickStart/Payments - Create/request.json b/postman/collection-dir/zen/Flow Testcases/QuickStart/Payments - Create/request.jsonindex ee35432532..aa51751ae1 100644--- a/postman/collection-dir/zen/Flow Testcases/QuickStart/Payments - Create/request.json+++ b/postman/collection-dir/zen/Flow Testcases/QuickStart/Payments - Create/request.json@@ -31,7 +31,15 @@"description": "Its my first payment request","authentication_type": "no_three_ds","return_url": "https://duck.com",- "setup_future_usage": "off_session",+ "setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"order_details": [{"amount": 6540,diff --git a/postman/collection-dir/zen/Flow Testcases/Variation Cases/Scenario2-Confirming the payment without PMD/Payments - Create/request.json b/postman/collection-dir/zen/Flow Testcases/Variation Cases/Scenario2-Confirming the payment without PMD/Payments - Create/request.jsonindex a6aef6ecb7..042a4bc1f7 100644--- a/postman/collection-dir/zen/Flow Testcases/Variation Cases/Scenario2-Confirming the payment without PMD/Payments - Create/request.json+++ b/postman/collection-dir/zen/Flow Testcases/Variation Cases/Scenario2-Confirming the payment without PMD/Payments - Create/request.json@@ -32,6 +32,14 @@"authentication_type": "no_three_ds","return_url": "https://duck.com","setup_future_usage": "on_session",+ "customer_acceptance": {+ "acceptance_type": "offline",+ "accepted_at": "1963-05-03T04:07:52.723Z",+ "online": {+ "ip_address": "127.0.0.1",+ "user_agent": "amet irure esse"+ }+ },"billing": {"address": {"line1": "1467",