mirror of
https://github.com/juspay/hyperswitch.git
synced 2025-10-29 17:19:15 +08:00
feat(connector): [MIFINITY] Implement payment flows and Mifinity payment method (#4592)
Co-authored-by: hyperswitch-bot[bot] <148525504+hyperswitch-bot[bot]@users.noreply.github.com> Co-authored-by: kiran.kummari <kiran.kummari@juspay.in>
This commit is contained in:
@ -20,7 +20,7 @@ use serde::{
|
||||
ser::Serializer,
|
||||
Deserialize, Deserializer, Serialize,
|
||||
};
|
||||
use time::PrimitiveDateTime;
|
||||
use time::{Date, PrimitiveDateTime};
|
||||
use url::Url;
|
||||
use utoipa::ToSchema;
|
||||
|
||||
@ -1604,6 +1604,7 @@ impl GetPaymentMethodType for WalletData {
|
||||
}
|
||||
Self::CashappQr(_) => api_enums::PaymentMethodType::Cashapp,
|
||||
Self::SwishQr(_) => api_enums::PaymentMethodType::Swish,
|
||||
Self::Mifinity(_) => api_enums::PaymentMethodType::Mifinity,
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -2415,6 +2416,8 @@ pub enum WalletData {
|
||||
CashappQr(Box<CashappQr>),
|
||||
// The wallet data for Swish
|
||||
SwishQr(SwishQrData),
|
||||
// The wallet data for Mifinity Ewallet
|
||||
Mifinity(MifinityData),
|
||||
}
|
||||
|
||||
impl GetAddressFromPaymentMethodData for WalletData {
|
||||
@ -2441,7 +2444,8 @@ impl GetAddressFromPaymentMethodData for WalletData {
|
||||
phone: None,
|
||||
})
|
||||
}
|
||||
Self::AliPayQr(_)
|
||||
Self::Mifinity(_)
|
||||
| Self::AliPayQr(_)
|
||||
| Self::AliPayRedirect(_)
|
||||
| Self::AliPayHkRedirect(_)
|
||||
| Self::MomoRedirect(_)
|
||||
@ -2573,6 +2577,14 @@ pub struct TouchNGoRedirection {}
|
||||
#[derive(Eq, PartialEq, Clone, Debug, serde::Deserialize, serde::Serialize, ToSchema)]
|
||||
pub struct SwishQrData {}
|
||||
|
||||
#[derive(Eq, PartialEq, Clone, Debug, serde::Deserialize, serde::Serialize, ToSchema)]
|
||||
pub struct MifinityData {
|
||||
#[schema(value_type = String)]
|
||||
pub destination_account_number: Secret<String>,
|
||||
#[schema(value_type = Date)]
|
||||
pub date_of_birth: Secret<Date>,
|
||||
}
|
||||
|
||||
#[derive(Eq, PartialEq, Clone, Debug, serde::Deserialize, serde::Serialize, ToSchema)]
|
||||
pub struct GpayTokenizationData {
|
||||
/// The type of the token
|
||||
|
||||
Reference in New Issue
Block a user