feat(payments): [Payment links] add hide card nickname field config for secure payment links (#6554)

Co-authored-by: Chikke Srujan <chikke.srujan@Chikke-Srujan-N7WRTY72X7.local>
Co-authored-by: hyperswitch-bot[bot] <148525504+hyperswitch-bot[bot]@users.noreply.github.com>
This commit is contained in:
chikke srujan
2024-11-18 17:01:53 +05:30
committed by GitHub
parent d32397f060
commit 0e026b70b6
14 changed files with 96 additions and 35 deletions

View File

@ -1,7 +1,5 @@
//! Commonly used constants
use std::collections::HashSet;
/// Number of characters in a generated ID
pub const ID_LENGTH: usize = 20;
@ -51,26 +49,12 @@ pub const SURCHARGE_PERCENTAGE_PRECISION_LENGTH: u8 = 2;
/// Header Key for application overhead of a request
pub const X_HS_LATENCY: &str = "x-hs-latency";
/// Default Payment Link Background color
pub const DEFAULT_BACKGROUND_COLOR: &str = "#212E46";
/// Default product Img Link
pub const DEFAULT_PRODUCT_IMG: &str =
"https://live.hyperswitch.io/payment-link-assets/cart_placeholder.png";
/// Default Merchant Logo Link
pub const DEFAULT_MERCHANT_LOGO: &str =
"https://live.hyperswitch.io/payment-link-assets/Merchant_placeholder.png";
/// Redirect url for Prophetpay
pub const PROPHETPAY_REDIRECT_URL: &str = "https://ccm-thirdparty.cps.golf/hp/tokenize/";
/// Variable which store the card token for Prophetpay
pub const PROPHETPAY_TOKEN: &str = "cctoken";
/// Default SDK Layout
pub const DEFAULT_SDK_LAYOUT: &str = "tabs";
/// Payment intent default client secret expiry (in seconds)
pub const DEFAULT_SESSION_EXPIRY: i64 = 15 * 60;
@ -80,15 +64,6 @@ pub const DEFAULT_INTENT_FULFILLMENT_TIME: i64 = 15 * 60;
/// Payment order fulfillment time (in seconds)
pub const DEFAULT_ORDER_FULFILLMENT_TIME: i64 = 15 * 60;
/// Default bool for Display sdk only
pub const DEFAULT_DISPLAY_SDK_ONLY: bool = false;
/// Default bool to enable saved payment method
pub const DEFAULT_ENABLE_SAVED_PAYMENT_METHOD: bool = false;
/// Default allowed domains for payment links
pub const DEFAULT_ALLOWED_DOMAINS: Option<HashSet<String>> = None;
/// Default ttl for Extended card info in redis (in seconds)
pub const DEFAULT_TTL_FOR_EXTENDED_CARD_INFO: u16 = 15 * 60;