mirror of
https://github.com/juspay/hyperswitch.git
synced 2025-10-29 17:19:15 +08:00
feat(payment_methods): add support for tokenising bank details and fetching masked details while listing (#2585)
Co-authored-by: shashank_attarde <shashank.attarde@juspay.in> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
This commit is contained in:
@ -811,10 +811,20 @@ pub struct CustomerPaymentMethod {
|
||||
#[schema(value_type = Option<Bank>)]
|
||||
pub bank_transfer: Option<payouts::Bank>,
|
||||
|
||||
/// Masked bank details from PM auth services
|
||||
#[schema(example = json!({"mask": "0000"}))]
|
||||
pub bank: Option<MaskedBankDetails>,
|
||||
|
||||
/// Whether this payment method requires CVV to be collected
|
||||
#[schema(example = true)]
|
||||
pub requires_cvv: bool,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, serde::Serialize, serde::Deserialize, ToSchema)]
|
||||
pub struct MaskedBankDetails {
|
||||
pub mask: String,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, serde::Serialize, serde::Deserialize)]
|
||||
pub struct PaymentMethodId {
|
||||
pub payment_method_id: String,
|
||||
|
||||
Reference in New Issue
Block a user