mirror of
https://github.com/juspay/hyperswitch.git
synced 2025-10-27 11:24:45 +08:00
feat(session): ability to request session token for specific wallets (#280)
Co-authored-by: Arun Raj M <jarnura47@gmail.com>
This commit is contained in:
@ -509,6 +509,15 @@ pub enum Connector {
|
||||
Worldpay,
|
||||
}
|
||||
|
||||
#[derive(Debug, serde::Deserialize, serde::Serialize, Clone)]
|
||||
#[serde(rename_all = "snake_case")]
|
||||
pub enum SupportedWallets {
|
||||
Paypal,
|
||||
ApplePay,
|
||||
Klarna,
|
||||
Gpay,
|
||||
}
|
||||
|
||||
impl From<AttemptStatus> for IntentStatus {
|
||||
fn from(s: AttemptStatus) -> Self {
|
||||
match s {
|
||||
|
||||
@ -751,15 +751,6 @@ pub struct PaymentsRetrieveRequest {
|
||||
pub connector: Option<String>,
|
||||
}
|
||||
|
||||
#[derive(Debug, serde::Deserialize, Clone)]
|
||||
#[serde(rename_all = "snake_case")]
|
||||
pub enum SupportedWallets {
|
||||
Paypal,
|
||||
ApplePay,
|
||||
Klarna,
|
||||
Gpay,
|
||||
}
|
||||
|
||||
#[derive(Debug, Default, Eq, PartialEq, serde::Deserialize, serde::Serialize, Clone)]
|
||||
pub struct OrderDetails {
|
||||
pub product_name: String,
|
||||
@ -777,6 +768,7 @@ pub struct Metadata {
|
||||
pub struct PaymentsSessionRequest {
|
||||
pub payment_id: String,
|
||||
pub client_secret: String,
|
||||
pub wallets: Vec<api_enums::SupportedWallets>,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, serde::Serialize, serde::Deserialize)]
|
||||
|
||||
Reference in New Issue
Block a user