-
Notifications
You must be signed in to change notification settings - Fork 3.9k
feat(router): Add support for confirm-intent proxy flow #8923
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
…h into add-confirm-proxy-flow
|
||
/// The card holder's name | ||
#[schema(value_type = String, example = "John Test")] | ||
pub card_holder_name: String, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please make this Optional
charges: None, | ||
client_source: None, | ||
client_version: None, | ||
customer_acceptance: None, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please fill this data since it is collected in the request
organization_id: payment_intent.organization_id.clone(), | ||
payment_method_type: payment_method_type_data | ||
.unwrap_or(common_enums::PaymentMethod::Card), | ||
payment_method_id: None, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please fill this as well
@@ -9,7 +9,7 @@ readme = "README.md" | |||
license.workspace = true | |||
|
|||
[features] | |||
default = ["common_default", "v1"] | |||
default = ["common_default", "v2"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
revert this to v1
Box::pin( | ||
transformers::construct_external_vault_proxy_payment_router_data( | ||
state, | ||
self.clone(), | ||
connector_id, | ||
merchant_context, | ||
customer, | ||
merchant_connector_account, | ||
merchant_recipient_data, | ||
header_payload, | ||
), | ||
) | ||
.await |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we construct v2 router data and then convert to v1 router data for future compatibility
@@ -880,6 +880,7 @@ where | |||
pub mandate_data: Option<api_models::payments::MandateIds>, | |||
pub payment_method: Option<payment_methods::PaymentMethod>, | |||
pub merchant_connector_details: Option<common_types::domain::MerchantConnectorAuthDetails>, | |||
pub external_vault_pmd: Option<payment_method_data::ExternalVaultPaymentMethodData>, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we have separate PaymentData for External Vault Confirm
Some(status) => status, | ||
None => match error.status_code { | ||
500..=511 => common_enums::enums::AttemptStatus::Pending, | ||
_ => common_enums::enums::AttemptStatus::Failure, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For unknown things we should not mark failure, only for the known and definite failure
we should mark failure
Some(status) => status, | ||
None => match error_response.status_code { | ||
500..=511 => common_enums::enums::AttemptStatus::Pending, | ||
_ => common_enums::enums::AttemptStatus::Failure, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For unknown things we should not mark failure, only for the known and definite failure we should mark failure
Type of Change
Description
Add support for confirm-intent proxy flow which accepts Card payment method data with card number vault token instead of raw card number.
Additional Changes
Motivation and Context
How did you test it?
Checklist
cargo +nightly fmt --all
cargo clippy