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(connector): [MIFINITY] Implement payment flows and Mifinity payment method #4592
base: main
Are you sure you want to change the base?
Conversation
…into mifinity-impl
…into mifinity-impl
@@ -1949,6 +1949,10 @@ pub(crate) fn validate_auth_and_metadata_type( | |||
klarna::transformers::KlarnaAuthType::try_from(val)?; | |||
Ok(()) | |||
} | |||
api_enums::Connector::Mifinity => { | |||
mifinity::transformers::MifinityAuthType::try_from(val)?; |
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.
mifinity::transformers::MifinityAuthType::try_from(val)?; | |
mifinity::transformers::MifinityAuthType::try_from(val)?; | |
mifinity::transformers::MifinityConnectorMetadataObject::try_from(connector_meta_data)?; |
#[serde(rename_all = "SCREAMING_SNAKE_CASE")] | ||
pub enum MifinityPaymentStatus { | ||
Successful, | ||
#[default] |
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.
default should not be implemented for payment status
refund_status: enums::RefundStatus::from(item.response.status), | ||
status: enums::AttemptStatus::from(status), | ||
response: Ok(types::PaymentsResponseData::TransactionResponse { | ||
resource_id: types::ResponseId::ConnectorTransactionId(transaction_reference), |
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.
instead of collecting all the reference_id, just take the first one.
} | ||
_ => Err(errors::ConnectorError::NotImplemented("Payment methods".to_string()).into()), | ||
} | ||
} | ||
} | ||
|
||
//TODO: Fill the struct with respective fields |
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.
remove todo's
dialing_code: String, | ||
nationality: api_models::enums::CountryAlpha2, | ||
email_address: Email, | ||
dob: Secret<Date>, | ||
} | ||
|
||
#[derive(Default, Debug, Serialize, Eq, PartialEq)] |
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 all the derives ?
Type of Change
Description
Additional Changes
Motivation and Context
How did you test it?
Response
redirection_url
in response complete the paymentpayment_id
Checklist
cargo +nightly fmt --all
cargo clippy