-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
feat(core): Connector specific validation for Payment Sync #2005
Conversation
connector_request_reference_id
as Transaction Id to Retrieve Payments59e065e
to
35a92c3
Compare
@@ -26,7 +26,7 @@ use crate::{ | |||
configs::settings::Connectors, | |||
connector, consts, | |||
core::errors::{self, CustomResult}, | |||
services::{request, ConnectorIntegration, ConnectorRedirectResponse}, | |||
services::{request, ConnectorIntegration, ConnectorRedirectResponse, ConnectorValidation}, |
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.
Do we need this import?
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.
Yes, since we are adding this trait to Payment, this import was made to add ConnectorValidation trait for api crate itself otherwise for all file where payment is implemented, we need to import services crate too for ConnectorValidation
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.
Just some nit picks, other than that looks good
None => types::ResponseId::NoResponseId, | ||
}; | ||
|
||
// [#44]: why should response be filled during request |
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.
We should in the future, also pick this up, as currently these are just work arounds
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.
Sure👍, will pick this up
Type of Change
Description
connector_request_reference_id
is being pass asmerchant_transaction_id
which will help in payment retrieval in case of connector timeout.Whether psync call is made is now handled at connector level to decide what parameters are required to make the call
For Bluesnap,
merchant_id
needs to be passed in connector meta_data to enable this featureAdditional Changes
Checklist
cargo +nightly fmt --all
cargo clippy